![6fe3f8993486c8a136b7faf10b20a9f6.png](https://img-blog.csdnimg.cn/img_convert/6fe3f8993486c8a136b7faf10b20a9f6.png)
转自
PostgreSQL神器之PostgRESTwww.jianshu.com![1c256c0ded851fbcf8107d5ce1b5cd0d.png](https://img-blog.csdnimg.cn/img_convert/1c256c0ded851fbcf8107d5ce1b5cd0d.png)
What is PostgREST
从字面上看 PostgREST 是 PostgreSQL+ RESTful的组合体,PostgreSQL是一个类似Mysql但比Mysql强大的多的关系性数据库。
PostgREST是haskell写的,以 postgres 数据库为基础,替你自动生成REST API。你只需要通过sql定义好数据库的table等,postgrest就能生成REST API。 PostgREST效率非常高,而且它连json的render 都在postgres中处理,性能反而还不错。
有这样的一张数据表结构 ```sql create table todos ( id serial primary key, done boolean not null default false, task text not null, due timestamptz );
insert into todos (task) values ('finish tutorial 0'), ('p