Forgot to add, updates to that particular table usually take the form:
INSERT INTO bugtest(a, b, c, d, e) VALUES (6, 'correct', 9, 1, 20) ON DUPLICATE KEY UPDATE d = d + VALUES(d), e = e + VALUES(e)
Where the table looks like the following:
CREATE TABLE `bugtest` (
`a` bigint(20) unsigned NOT NULL,
`b` enum('correct','incorrect','unanswered','unexpected','invalid','punished') NOT NULL,
`c` int(10) unsigned NOT NULL,
`d` bigint(20) unsigned NOT NULL,
`e` bigint(20) unsigned NOT NULL,
PRIMARY KEY (`a`,`b`,`c`)
) ENGINE=InnoDB DEFAULT CHARSET=latin1
Apart from that, it's also renamed with:
RENAME TABLE bugtest TO tmptable, morebugtest TO bugtest, tmptable TO morebugtest;
I suspect the combination of both might be triggering this issue, but haven't been able to reproduce it by hand yet...
Forgot to add, updates to that particular table usually take the form:
VALUES
(6, 'correct', 9, 1, 20)
ON DUPLICATE KEY UPDATE
d = d + VALUES(d),
e = e + VALUES(e)
INSERT INTO bugtest(a, b, c, d, e)
Where the table looks like the following: ,'incorrect' ,'unanswered' ,'unexpected' ,'invalid' ,'punished' ) NOT NULL,
CREATE TABLE `bugtest` (
`a` bigint(20) unsigned NOT NULL,
`b` enum('correct'
`c` int(10) unsigned NOT NULL,
`d` bigint(20) unsigned NOT NULL,
`e` bigint(20) unsigned NOT NULL,
PRIMARY KEY (`a`,`b`,`c`)
) ENGINE=InnoDB DEFAULT CHARSET=latin1
Apart from that, it's also renamed with:
RENAME TABLE bugtest TO tmptable, morebugtest TO bugtest, tmptable TO morebugtest;
I suspect the combination of both might be triggering this issue, but haven't been able to reproduce it by hand yet...