Bug #104627 ERROR 1194 (HY000): Table 't' is marked as crashed and should be repaired
Submitted: 15 Aug 2021 23:29 Modified: 1 Nov 2022 2:19
Reporter: Roel Van de Paar Email Updates:
Status: Verified Impact on me:
None 
Category:MySQL Server: CSV Severity:S2 (Serious)
Version:5.7, 8.0, 5.7.35, 8.0.26, 8.0.29 OS:Any
Assigned to: CPU Architecture:Any

[15 Aug 2021 23:29] Roel Van de Paar
Description:
8.0.24-opt>SELECT * FROM t;
ERROR 1194 (HY000): Table 't' is marked as crashed and should be repaired

5.5.62-dbg>SELECT * FROM t;
ERROR 1194 (HY000): Table 't' is marked as crashed and should be repaired

How to repeat:
SET sql_mode='no_zero_date';
CREATE TABLE t (a DATETIME NOT NULL) ENGINE=CSV;
CREATE TEMPORARY TABLE t (b INT) ENGINE=InnoDB;
DROP TABLE t;
INSERT INTO t VALUES (1);
SELECT * FROM t;
[16 Aug 2021 6:21] MySQL Verification Team
Hello Roel,

Thank you for the report and test case.

regards,
Umesh
[16 Aug 2021 7:03] Roel Van de Paar
Thanks Umesh. Why was 5.5 and 5.6 removed from affected versions?
[16 Aug 2021 9:04] MySQL Verification Team
Hi Roel,

Please note that 5.6 reached EOL in February 2021 - https://www.mysql.com/support/eol-notice.html and MySQL 5.6.51 was the last release of the MySQL 5.6 series. 
Lowest checked (5.5,5.6) version is usually affected version in the system and to avoid setting affected version such as 5.5/5.6, I intentionally removed while copying internally. Thank you!

regards,
Umesh
[1 Nov 2022 2:19] Roel Van de Paar
Additional testcase

SET sql_mode='';
CREATE TABLE t1 (a DATE NOT NULL) ENGINE=CSV;
INSERT INTO t1 VALUES();
SET sql_mode=TRADITIONAL;
SELECT 1 FROM t1 WHERE ROW(a,a) NOT IN ((1,1),(2,2));

8.0.29-dbg>SELECT 1 FROM t1 WHERE ROW(a,a) NOT IN ((1,1),(2,2));
ERROR 1194 (HY000): Table 't1' is marked as crashed and should be repaired