pg
8.23.1 · 30 Sep 2026MIT106.3M / weekRepositorynpmAtom feed
7.18.2 is the newest release of 7.x.
In short
7 breaking3 new
- Breaking
Drop support for node <
4.x. - Breaking
Remove
pg.connectpg.endandpg.cancelsingleton methods. - Breaking
Client#connect(callback)now returnsundefined. It used to return an event emitter. - Breaking
Upgrade pg-pool to
2.x. - Breaking
Upgrade pg-native to
2.x. - Breaking
Standardize error message fields between JS and native driver. The only breaking changes were in the native driver as its field names were brought into alignment with the existing JS driver field names.
- Breaking
Result from multi-statement text queries such as
SELECT 1; SELECT 2;are now returned as an array of results instead of a single result with 1 array containing rows from both queries.
Security
1 advisory affects 7.0.0; 7.1.2 fixes them
- CriticalRemote Code Execution in pgGHSA-wc9v-mj63-m9g5 · 24 Jul 2018Fixed in 7.1.2
Release note
Breaking Changes
- Breaking
Drop support for node <
4.x. - Breaking
Remove
pg.connectpg.endandpg.cancelsingleton methods. - Breaking
Client#connect(callback)now returnsundefined. It used to return an event emitter. - Breaking
Upgrade pg-pool to
2.x. - Breaking
Upgrade pg-native to
2.x. - Breaking
Standardize error message fields between JS and native driver. The only breaking changes were in the native driver as its field names were brought into alignment with the existing JS driver field names.
- Breaking
Result from multi-statement text queries such as
SELECT 1; SELECT 2;are now returned as an array of results instead of a single result with 1 array containing rows from both queries.
Please see here for a migration guide
Enhancements
Overhauled documentation: node-postgres.com.
Add
Client#connect() => Promise<void>andClient#end() => Promise<void>calls. Promises are now returned from all async methods on clients if and only if no callback was supplied to the method.Add
connectionTimeoutMillisto pg-pool.
A whole project to check? Paste its package.json in the dependency check: every deprecated, outdated or vulnerable dependency, with what to upgrade to. Free, no account.