From db52fcb7bcba463622bba5bf413ec8e8220708b1 Mon Sep 17 00:00:00 2001 From: Jon Morehouse Date: Wed, 30 Apr 2014 13:09:28 -0700 Subject: [PATCH] Minor documentation change for readme. Make connection string example a bit more intuitive --- README.md | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index f4592d6b..a7b634f5 100644 --- a/README.md +++ b/README.md @@ -16,13 +16,13 @@ Typically you will access the PostgreSQL server through a pool of clients. node ```javascript var pg = require('pg'); -var conString = "postgres://postgres:1234@localhost/postgres"; +var conString = "postgres://username:password@localhost/database"; pg.connect(conString, function(err, client, done) { if(err) { - return console.error('error fetching client from pool', err); + return console.error('error fetching client from pool', err); } - client.query('SELECT $1::int AS numbor', ['1'], function(err, result) { + client.query('SELECT $1::int AS number', ['1'], function(err, result) { //call `done()` to release the client back to the pool done(); @@ -45,7 +45,7 @@ var pg = require('pg'); //or native libpq bindings //var pg = require('pg').native -var conString = "postgres://postgres:1234@localhost/postgres"; +var conString = "postgres://username:password@localhost/database"; var client = new pg.Client(conString); client.connect(function(err) {