First output is response from nosql engine and second is the data passed in.
if the collection field is left empty, then we try to look at flowdata.get('collection'), to set this value you need to use flowdata.set('collection', '<collection-name>') in previous component (currently only function can be used)
- will insert recieved data
- expects data to be an Object
- returns error, success, id
- will read a document by id
- expects data to be an Object with an
idproperty - returns error, response
- will update document by id
- expects data to be an Object with
idproperty and all the props to be updated - returns error, response
- if response is 0 then update failed
- will remove document by id
- expects data to be an Object with an
idproperty - returns error, response
- if response is 0 then remove failed
- will query DB
- expects data to be an Array as shown bellow
- returns error, response
[
['where', 'sensor', 'temp'], // builder.where('sensor', 'temp');
['limit', 2] // builder.limit(2);
]