I’m working on a project to get the likes of web developers to make more effective use of Postgres. This amounts to saying that much of the M in MVC should be implemented as code and relations in Postgres. The more I think about this, the more I see that a model written in Node, say, that just does queries against the database would be written quite differently as PLV8 stored procedures, triggers and functions inside Postgres. It would have a more purely functional style, you would implement many things as functions that could be used in views and queries, you can write functions that are callable between programming languages, you can write functions that act as result set generators. And I’m sure there are other things I’ve not thought about. Oh: testing will likely be rather different. Are there any good resources about using Postgres as a programming platform from within, as it were? Thanks in advance. |