Some of you might have read this in my blog, but for those who haven't, the DB-API pundits here might enjoy learning about plpydbapi, a DB-API layer on top of PL/Python, which allows (with some restrictions) running DB-API using applications inside a PostgreSQL server. http://petereisentraut.blogspot.com/2011/11/plpydbapi-db-api-for-plpython.html