MariaDB Connector/Node.js is used to connect applications developed on Node.js to MariaDB and MySQL databases. MariaDB Connector/Node.js is LGPL licensed.
GNU Lesser General Public License v2.1
369
stars
91
forks
source link
Connection stops responding after exception thrown by 'batch' operation. #259
C:\Development\YADAMU\src\scratch\mariadb>node batchIssue2.js
ROWS 9
TypeError: Cannot read properties of undefined (reading '0')
at BatchBulk.sendComStmtBulkExecute (C:\Development\YADAMU\src\node_modules\mariadb\lib\cmd\batch-bulk.js:261:32)
at BatchBulk.start (C:\Development\YADAMU\src\node_modules\mariadb\lib\cmd\batch-bulk.js:61:10)
at Connection.addCommandEnablePipeline (C:\Development\YADAMU\src\node_modules\mariadb\lib\connection.js:1087:11)
at Connection.executeBulkPromise (C:\Development\YADAMU\src\node_modules\mariadb\lib\connection.js:286:10)
at new Promise (<anonymous>)
at C:\Development\YADAMU\src\node_modules\mariadb\lib\connection.js:210:16
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
at async main (file:///C:/Development/YADAMU/src/scratch/mariadb/batchIssue2.js:43:17)
Atttempting Rollback to SAVEPOINT
^C
C:\Development\YADAMU\src\scratch\mariadb>
The line
results = await conn.query(`ROLLBACK TO SAVEPOINT YADAMU_INSERT`)
Running the Following Code
Results in the following
The line
never returns contol to the calling program. It is necessary to Cntrl-C the program in order to regain control. The testdata needed to run this example is connected to https://github.com/mariadb-corporation/mariadb-connector-nodejs/issues/258