Stored procedures are frequently used by database administrators to encapsulate application data logic, but the web development community has never embraced them because of concerns about portability, maintainability and a general distaste for SQL.
But the currently standard alternative, the duo of database abstraction and ORM, comes with some baggage of its own: poor performance, underutilization of advanced database features, and ad-hoc query syntaxes that end up being more complex than SQL itself.
The growing acceptance of NoSQL databases show us that contemporary web developers are again willing to consider vendor-specific database libaries for application development, so let's see what one vendor in particular - PostgreSQL - has to offer.
In this talk I'll show how building an API based on a mix of simple Ruby objects and Postgres stored procedures can be a very compelling alternative to ORM.
This talk was given in Spanish at Rubyconf Argentina in 2011.