pg
package.
Hi all, My query looks like
select 1,2,3,4;
in results.recordset, what i was exptecting is for the object result.recordset.toTable()
{
"columns":[
{"name":"","nullable":false},
{"name":"","nullable":false},
{"name":"","nullable":false},
{"name":"","nullable":false}
],"
rows":[
[1,2,3,4]
]
}
instead I am getting
{"columns":[{"name":"","nullable":false}],"rows":[[[1,2,3,4]]]}
How to overcome this? (Results are automatically grouped in to object based on column headers. in my case no column names are preset. )
Hi i am using mssql nodejs package, encrypted data and NTLM login is throwing issue
(node:9988) [DEP0064] DeprecationWarning: tls.createSecurePair() is deprecated. Please use tls.Socket instead.
my Config File look like this
var config = {
"userName": "user.name",
"password": "password",
"server": "servername",
"domain": "DOMAIN_NAME_CAPITALIZED_AND_NOT_FQDM",
"options": {
"encrypt": false
}
};
bulk
requests and inserting geometry
type data? I have a pretty simple scenario but specifically introduction a geometry column results in this error TypeError: "value" argument is out of bounds
at checkInt (buffer.js:1041:11)
at Buffer.writeUInt16LE (buffer.js:1099:5)
at WritableTrackingBuffer.writeUInt16LE (/var/task/node_modules/tedious/lib/tracking-buffer/writable-tracking-buffer.js:87:19)
at WritableTrackingBuffer.writeUsVarbyte (/var/task/node_modules/tedious/lib/tracking-buffer/writable-tracking-buffer.js:243:12)
at Object.writeParameterData (/var/task/node_modules/tedious/lib/data-type.js:864:25)
at BulkLoad.addRow (/var/task/node_modules/tedious/lib/bulk-load.js:141:17)
at parent.acquire (/var/task/node_modules/mssql/lib/tedious.js:473:16)
at _acquire.then.connection (/var/task/node_modules/mssql/lib/base.js:172:42)
at process._tickDomainCallback (internal/process/next_tick.js:135:7)
this[data] = await new Promise((resolve, reject) => {
var request = new sql.Request(this[db]);
var query = queries.getErrors;
//get the records for the block #blockNo
request.on('row', (row) => {
console.log(`Got row!`);
});
request.query(query, (err, result) => {
if (err) {
console.error(`An error occurred while processing the request: \n${err}`);
reject(err);
}
else {
console.info(`Received ${result.recordset.length} records.`);
resolve(result.recordset);
}
});
}) || [];
Problem is that even though I get 500+ records back, the row event never fires. Any suggestions?
(node:18908) UnhandledPromiseRejectionWarning: TypeError: Cannot read property 'Symbol(Symbol.iterator)' of undefined
warning.js:18
at Function.all (<anonymous>)
at c:\Users\rutherfordc\Documents\GitHub\migration-plus\index.js:10:11
at <anonymous>
at process._tickCallback (internal/process/next_tick.js:188:7)
(node:18908) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 1)
warning.js:18
(node:18908) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.
warning.js:18
(node:18908) UnhandledPromiseRejectionWarning: ReferenceError: results is not defined
warning.js:18
at c:\Users\rutherfordc\Documents\GitHub\migration-plus\index.js:15:11
at <anonymous>
at process._tickCallback (internal/process/next_tick.js:188:7)
(node:18908) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 2)
transaction.begin('SERIALIZABLE').then(() => { ...
dhensby on master
Update changelog for v5 Merge pull request #796 from dh… (compare)