0.2.0 • Published 9 years ago

ezpg v0.2.0

Weekly downloads
-
License
MIT
Repository
-
Last release
9 years ago

ezpg Build Status

var ezpg = require('ezpg');


ezpg.connection(function(err, client, done){
	// normal pq stuff
	client.query('select 1;', function(err, result){
		//done()
	});

	// ez'er pg function
	client.func('pg_database_size', ['template1'], function(err, result){
		console.log('your db is ' + result[0] + 'bytes.');
		done();
	});
});

ezpg.transaction(function(err, client, commit, rollback){
	client.query('create table relay.thisismynewtabkldasfadsfdsfads(id smallint);', function(err, result){
		
		// jk
		rollback();
	});
});
0.2.0

9 years ago

0.1.12

9 years ago

0.1.11

9 years ago

0.1.10

10 years ago

0.1.9

10 years ago

0.1.8

10 years ago

0.1.7

10 years ago