Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

node js firebird example

Firebird.attach(options, function(err, db) {     if (err)        throw err;     // db = DATABASE    // INSERT STREAM as BLOB    db.query('INSERT INTO USERS (ID, ALIAS, FILE) VALUES(?, ?, ?)', [1, 'Peter', fs.createReadStream('/users/image.jpg')], function(err, result) {        // IMPORTANT: close the connection        db.detach();    });});
Source by www.npmjs.com #
 
PREVIOUS NEXT
Tagged: #node #js #firebird
ADD COMMENT
Topic
Name
6+4 =