mirror of
https://github.com/brianc/node-postgres.git
synced 2026-01-18 15:55:05 +00:00
fix query in readme - closes #244
This commit is contained in:
parent
21c31f69e6
commit
9286a66303
@ -22,7 +22,7 @@ var conString = "tcp://postgres:1234@localhost/postgres";
|
||||
//note: error handling omitted
|
||||
var client = new pg.Client(conString);
|
||||
client.connect(function(err) {
|
||||
client.query('SELECT NOW() AS theTime', function(err, result) {
|
||||
client.query('SELECT NOW() AS "theTime"', function(err, result) {
|
||||
console.log(result.rows[0].theTime);
|
||||
//output: Tue Jan 15 2013 19:12:47 GMT-600 (CST)
|
||||
})
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user