<commit_before># NuoDB    - node.js

[![Build Status](https://travis-ci.org/nuodb/node-db-nuodb.png?branch=master)](https://travis-ci.org/nuodb/node-db-nuodb)

This module builds a native [Google V8](https://developers.google.com/v8/) C++ binding to let you easily integrate your [node.js](http://www.nodejs.org) web applications with [NuoDB](http://www.nuodb.com).

### Requirements
`make`  
`g++`

### Install

    $ npm install db-nuodb

### Example

```javascript
var nuodb = require('db-nuodb');
new nuodb.Database({
    hostname: 'localhost',
    user: 'root',
    password: 'password',
    database: 'node'
}).connect(function(error) {
    if (error) {
        return console.log("CONNECTION ERROR: " + error);
    }

    this.query().select('*').from('users').execute(function(error, rows) {
        if (error) {
            return console.log('ERROR: ' + error);
        }
        console.log(rows.length + ' ROWS');
    });
});<commit_msg>Update README, corrected example provided<commit_after># NuoDB    - node.js

[![Build Status](https://travis-ci.org/nuodb/node-db-nuodb.png?branch=master)](https://travis-ci.org/nuodb/node-db-nuodb)

This module builds a native [Google V8](https://developers.google.com/v8/) C++ binding to let you easily integrate your [node.js](http://www.nodejs.org) web applications with [NuoDB](http://www.nuodb.com).

### Requirements
`make`  
`g++`

### Install

    $ npm install db-nuodb

### Example

```javascript
var nuodb = require('db-nuodb');
new nuodb.Database({
    hostname: 'localhost',
    user: 'dba',
    password: '<PASSWORD>',
    database: 'test',
    schema: 'hockey'
}).on('error', function(error) {
    console.log('ERROR: ' + error);
}).on('ready', function(server) {
    console.log('Connected to ' + server.hostname + ' (' + server.version + ')');
}).connect();
{'fraction_non_alphanumeric': 0.19298245614035087, 'fraction_numerical': 0.0021929824561403508, 'mean_word_length': 3.643765903307888, 'pattern_counts': {'":': 0, '<': 4, '<?xml version=': 0, '>': 4, 'https://': 6, 'lorem ipsum': 0, 'www.': 4, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2154603', 'n_tokens_mistral': 639, 'n_tokens_neox': 615, 'n_words': 127}