Hacker News new | past | comments | ask | show | jobs | submit login

PostgreSQL already gives you SQL syntax errors(try creating a VIEW with a misspelled SELCT), column type errors(try doing a `select 'asdf'::int;`), wrong number of arguments on a sp call(try putting one more argument to `select int4_sum(2, 3);`).

Thanks to PostgreSQL transactional DDL[1] you would get all of these errors at creation-time and without any change to your database if any migration is wrong. There's no need for a SQL codegen to get this already included safety.

Btw, PostgREST is not only a JSON API. Out of the box, it supports CSV, plain text and binary output and it's extendable for supporting other media types[2]. If you have to output xml by using pg xml functions you can do so with PostgREST.

[1]: https://wiki.postgresql.org/wiki/Transactional_DDL_in_Postgr...

[2]: http://postgrest.org/en/v6.0/configuration.html#raw-media-ty...




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: