node-pg-query icon indicating copy to clipboard operation
node-pg-query copied to clipboard

Allowing for own connection params with backwards compatibility

Open owencraig opened this issue 9 years ago • 0 comments

When used as default in an app (such as an express web app), you're only able to have one connection at a time. We've got a use case which would benefit from the ease of calling just the query interface but to have multiple connections possible.

This allows for a non-breaking usage with

query.connectionParameters = 'foo';
query.query('select * from bar');

But also extends the interface with

query.ownConnection('foo','select * from bar')

owencraig avatar Mar 04 '16 19:03 owencraig