1615
MySQLERRORNotableReplicationHIGH confidence
Row injection impossible in STATEMENT binlog mode
Production Risk
Medium — the row injection fails; replication may stall.
What this means
A BINLOG row injection statement cannot be executed when binlog_format is set to STATEMENT.
Why it happens
- 1Attempting to replay a row-based binary log event (via BINLOG statement) when binlog_format=STATEMENT.
How to reproduce
trigger — this will error
trigger — this will error
SET SESSION binlog_format = 'STATEMENT'; BINLOG '...'; -- row injection
expected output
ERROR 1615 (HY000): Cannot execute row injection: impossible to write to the binary log since BINLOG_FORMAT = STATEMENT.
Fix
Switch to ROW format before applying row injections
Switch to ROW format before applying row injections
SET SESSION binlog_format = 'ROW'; BINLOG '...';
Why this works
Row injection events require ROW or MIXED binary log format.
Sources
Official documentation ↗
MySQL 8.0 — 1615 ER_BINLOG_ROW_INJECTION_AND_STMT_MODE
Content generated with AI assistance and reviewed for accuracy. Found an error? hello@errcodes.dev