unhandledrejection
huineng opened this issue · 0 comments
huineng commented
ibm_db 3.2.4. node 20.12.2
i was doing some development as usual using some
try { await conn.query(sql,bindings) } catch (err) { throw err} (or Promise.reject)
the problem was that i by mistake provided for bindings [['string']] instead of ['string']
So i got my rejecting and this had a message like
stack: Error: Wrong param format!
at /node_modules/ibm_db/lib/odbc.js:677:19
at SimpleQueue.next (/node_modules/ibm_db/lib/simple-queue.js:34:5)
at SimpleQueue.maybeNext (/node_modules/ibm_db/lib/simple-queue.js:22:10)
at SimpleQueue.push (/node_modules/ibm_db/lib/simple-queue.js:15:8)
at Database.query (/node_modules/ibm_db/lib/odbc.js:520:14)
i guess this is from this line
Line 988 in a2f0018
fine
But then i got also a unhandledrejection with reason
reason: Error: [IBM][CLI Driver] CLI0123E SQL data type out of range. SQLSTATE=HY004
so it looks to me the code doesn't stop at the first error
thanks