This is a read-only copy of the MariaDB Knowledgebase generated on 2024-11-21. For the latest, interactive version please visit https://mariadb.com/kb/.

COM_STMT_BULK_EXECUTE

MariaDB starting with 10.2.7

Executes a bulk insert of a previously prepared statement.

A command that returns a resultset will return an error (Error packet).

Direction

Client to server.

Fields

Flags

bulk flags

SEND_UNIT_RESULTS64Return generated affected rows and auto-increment IDs as a resultset (only when server supports MARIADB_CLIENT_BULK_UNIT_RESULTS capability)
SEND_TYPES_TO_SERVER128Send types to server

parameter type flag:

128unsigned

parameter indicator

0NONEValue follow
1NULLValue is null
2DEFAULTFor INSERT/UPDATE, value is default
3IGNOREValue is default for insert, Is ignored for update

COM_STMT_BULK_EXECUTE response

The server can answer with 3 different responses:

  • 0xff: ERR_Packet if any errors occur.
  • 0x00: OK_packet when query execution works without resultset.
  • a resultset containing affected rows and auto-increment IDs when bulk flag SEND_UNIT_RESULTS is set
Content reproduced on this site is the property of its respective owners, and this content is not reviewed in advance by MariaDB. The views, information and opinions expressed by this content do not necessarily represent those of MariaDB or any other party.