brianc/node-postgres — pull request #697 by sehrope (2014-12-10 22:13:36+00:00)
Title: Add sehrope/node-pg-db to Extras in README

[`pg-db`](https://github.com/sehrope/node-pg-db) is a module I put together that adds a bunch of things atop node-postgres:

* Simple interface (ex: `db.query(sql, [params], function(err, rows))` or `db.queryOne(sql, [params], function(err, row))`)
* Named parameter support (ex: `... WHERE foo = :foo` instead of `... WHERE foo = $1`)
* Transactions (more info below)
* Event hooks (ex: log all SQL that's executed or execute non-transactional hook on commit/rollback)

Transactions are implemented using domains. Database interactions automatically take part in an ongoing transaction so there's no need to manually pass a `Client` object around. Here's an example: https://github.com/sehrope/node-pg-db-examples/blob/master/src/tx.coffee