[CONJS-245] batch failing when using bulk and metaAsArray Created: 2023-02-28  Updated: 2023-02-28  Resolved: 2023-02-28

Status: Closed
Project: MariaDB Connector/node.js
Component/s: batch
Affects Version/s: 3.0.2, 3.0.0, 3.0.1, 3.1.0
Fix Version/s: 3.1.1

Type: Bug Priority: Major
Reporter: Diego Dupin Assignee: Diego Dupin
Resolution: Fixed Votes: 0
Labels: None


 Description   

see https://github.com/mariadb-corporation/mariadb-connector-nodejs/issues/235
batch fails when using bulk and metaAsArray with error :

TypeError: Cannot read properties of undefined (reading 'affectedRows')
    at BatchBulk.success (...\node_modules\mariadb\lib\cmd\batch-bulk.js:388:27)
    at BatchBulk.readOKPacket (...\node_modules\mariadb\lib\cmd\parser.js:182:19)
    at BatchBulk.readResponsePacket (...\node_modules\mariadb\lib\cmd\parser.js:49:21)
    at PacketInputStream.receivePacketBasic (...\node_modules\mariadb\lib\io\packet-input-stream.js:80:9)
    at PacketInputStream.onData (...\node_modules\mariadb\lib\io\packet-input-stream.js:130:20)

globally, metaAsArray option is not always respected when using batch according to cases.


Generated at Thu Feb 08 03:23:49 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.