'Error: NJS-069: node-oracledb 4.2.0 requires Node.js 8.16 or later
I am using python to host a local web server. I am using oracleDB in a javascript to execute inserts into the DB. I used browserify to compile the modules. However, when I run the web page, I am getting the error above.
I have installed oracledb v4.2.0 and node.js version v18.1.0
var oracledb = require('oracledb');
oracledb.initOracleClient({libDir: 'C:\\oracle\\instantclient_19_6'});
function getClientDetails() {
var connectData = {
user: "user",
password: "password",
connectString: "host"
}
oracledb.getConnection(
connectData,
function(err,connection)
{
if (err) {
console.log("Error connecting to db:", err);
return;
}
connection.execute("update merchant_accounts set key_id = 000000002; commit;",
[],
{outFormat: oracledb.OBJECT},
function(err, results)
{
if (err) {
console.log("Error executing query:", err);
return;
}
console.log(results.rows);
ReleaseCon(connection);
return;
});
})
};
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|
