You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm using all latest versions node - 10,npm -6.9 ,mssql-5.1.0, msnodesqlv8-0.8.3
I have deployed the API in iis and when I'm moving to iisnode.local:88, I'm getting the error :[DEP0005] DeprecationWarning: Buffer() is deprecated due to security and usability issues. Please use the Buffer.alloc(), Buffer.allocUnsafe(), or Buffer.from() methods instead.
Where exactly this needs to be modified ?
My Code :
var express = require('express');
var app = express();
app.get('/', function (req, res) {
var sql = require("mssql");
// config for your database
var config = {
driver : 'msnodesqlv8',
server : "abc",
port : 1433,
options: {
trustedConnection: true
},
database: 'DBtest'
};
// connect to your database
sql.connect(config, function (err) {
if (err) console.log(err);
// create Request object
var request = new sql.Request();
// query to the database and get the records
request.query('select * from employee', function (err, recordset) {
if (err) console.log(err)
// send records as a response
res.send(recordset);
});
});
});
var server = app.listen(5000, function () {
console.log('Server is running..');
});
The text was updated successfully, but these errors were encountered:
I'm using all latest versions node - 10,npm -6.9 ,mssql-5.1.0, msnodesqlv8-0.8.3
I have deployed the API in iis and when I'm moving to iisnode.local:88, I'm getting the error :[DEP0005] DeprecationWarning: Buffer() is deprecated due to security and usability issues. Please use the Buffer.alloc(), Buffer.allocUnsafe(), or Buffer.from() methods instead.
Where exactly this needs to be modified ?
My Code :
var express = require('express');
var app = express();
app.get('/', function (req, res) {
});
var server = app.listen(5000, function () {
console.log('Server is running..');
});
The text was updated successfully, but these errors were encountered: