Idk why you got downvoted. It's an excellent question.
For those who don't know, with PostgREST you write all your application logic in SQL, and you export schemas (which are a subset of your actual schemas) with a RESTful API automatically generated by PostgREST.
Meanwhile PostgREST is built on top of PostgreSQL, which is statically typed, and is written in Haskell, which is also statically typed.
Why would I want to interact with my database over the network when I can just...do it locally? It's orders of magnitudes slower and more wasteful and it doesn't even provide all the guarantees that using actual SQL or an ORM does.
If you are using PostgREST as intended, you don't have an application layer any more. It's not something extra you put in between the application and the database, but it replaces the application.
cryptonector|1 year ago
For those who don't know, with PostgREST you write all your application logic in SQL, and you export schemas (which are a subset of your actual schemas) with a RESTful API automatically generated by PostgREST.
Meanwhile PostgREST is built on top of PostgreSQL, which is statically typed, and is written in Haskell, which is also statically typed.
satvikpendem|1 year ago
kccqzy|1 year ago