Nosqwal adapter for Orientdb
$ npm install --save nosqwal-orientdb
const nosqwalOrientdb = require('nosqwal-orientdb');
const db = nosqwalOrientdb();
const userCollection = db.defineCollection('user');
userCollection.create({
username: 'Alice',
password: '*****'
})
.then(alice => {
return userCollection.query(
where: {
username: {
$eq: 'Alice'
}
},
limit: 1
});
})
.then(users => {
console.log(users[0].username);
//=> 'Alice'
});
Retuns a noSqwal instance, see api here
Type: string
Default: localhost
Hostname of the server
Type: number
Default: 2424
Port of the server
Type: string
Default: default
Database name
Type: string
Default: admin
Username to connect to the database
Type: string
Default: admin
Password to connect to the database
MIT © Thomas Sileghem