Skip to content

Commit

Permalink
docs update.
Browse files Browse the repository at this point in the history
  • Loading branch information
Vitaly Tomilov committed Mar 6, 2015
1 parent f1976e2 commit 349e328
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ For more details see [ConnectionParameters] class in [PG], such as additional co

### 4. Instantiate your database
```javascript
var db = new pgp(cn); // create a new database instance based on the connection details
var db = new pgp(cn); // create a new database instance from the connection details
```
There can be multiple database objects instantiated in the application from different connection details.

Expand All @@ -67,7 +67,7 @@ queryResult = {
```
In the following generic-query example we indicate that the call can return any number of rows:
```javascript
db.query("select * from users", queryResult.none | queryResult.many);
db.query("select * from users", queryResult.many | queryResult.none);
```
which is equivalent to calling:
```javascript
Expand All @@ -86,7 +86,7 @@ The mixed-result methods are:
Each of the query calls returns a [Promise] object, as shown below, to be used in the standard way.
And when the expected and actual results do not match, the call will be rejected.
```javascript
db.many("select * from users")
db.manyOrNone("select * from users")
.then(function(data){
console.log(data); // printing the data returned
}, function(reason){
Expand Down

0 comments on commit 349e328

Please sign in to comment.