[MDEV-4533] TokuDB: IGNORE clause doesn't work with ROW binlog format Created: 2013-05-15  Updated: 2014-05-06  Resolved: 2014-05-06

Status: Closed
Project: MariaDB Server
Component/s: None
Affects Version/s: 5.5.36, 10.0.10
Fix Version/s: 5.5.38, 10.0.11

Type: Bug Priority: Trivial
Reporter: Elena Stepanova Assignee: Unassigned
Resolution: Fixed Votes: 0
Labels: tokudb, upstream

Issue Links:
Relates
relates to MDEV-4507 Include TokuDB storage engine Closed

 Description   

When binary log is enabled in ROW format, statements like DELETE IGNORE ... etc. fail with ER_BINLOG_ROW_MODE_AND_STMT_ENGINE (Cannot execute statement: impossible to write to binary log since BINLOG_FORMAT = ROW and at least one table uses a storage engine limited to statement-based logging), while the same statements without IGNORE are executed all right. It works the same way on MariaDB-5.5.30-TokuDB-7.0.1, but it would be good to make sure it's an intentional limitation and not an oversight.

MariaDB [test]> DROP TABLE IF EXISTS t1;
Query OK, 0 rows affected (0.35 sec)
 
MariaDB [test]> CREATE TABLE t1 (a INT(11), b CHAR(8)) ENGINE=TokuDB;
Query OK, 0 rows affected (0.92 sec)
 
MariaDB [test]> INSERT INTO t1 (a,b) VALUES (10000,'foobar'),(1,'a'),(2,'b'),(3,'c'),(4,'d'),(5,'e');
Query OK, 6 rows affected (0.43 sec)
Records: 6  Duplicates: 0  Warnings: 0
 
MariaDB [test]> DELETE IGNORE FROM t1;
ERROR 1662 (HY000): Cannot execute statement: impossible to write to binary log since BINLOG_FORMAT = ROW and at least one table uses a storage engine limited to statement-based logging.
MariaDB [test]> DELETE FROM t1;
Query OK, 6 rows affected (0.18 sec)

Test case (for MariaDB):

# run with --mysqld=--plugin-load=ha_tokudb, 
# because installing engine at runtime causes assertion failure MDEV-6082
 
--source include/have_binlog_format_row.inc
 
# install soname 'ha_tokudb.so';
DROP TABLE IF EXISTS t1;
CREATE TABLE t1 (a INT(11), b CHAR(8)) ENGINE=TokuDB;
INSERT INTO t1 (a,b) VALUES (10000,'foobar'),(1,'a'),(2,'b'),(3,'c'),(4,'d'),(5,'e');
DELETE IGNORE FROM t1;
 
# uninstall soname 'ha_tokudb.so';

bzr version-info

revision-id: holyfoot@askmonty.org-20130514121908-d6tp4zsdkim0q4dg
revno: 3768
branch-nick: 5.5-hf-tokudb



 Comments   
Comment by Rich Prohaska [ 2014-04-13 ]

the workaround is to set tokudb_pk_insert_mode=2.

Comment by Rich Prohaska [ 2014-04-28 ]

fixed in tokudb 7.1.6

Generated at Thu Feb 08 06:57:09 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.