CREATE DATABASE repair_test;
USE repair_test;
CREATE TABLE diaries (
id INT PRIMARY KEY AUTO_INCREMENT,
title TEXT,
body TEXT,
FULLTEXT INDEX body_index (body)
) COMMENT = 'engine "innodb"' DEFAULT CHARSET UTF8MB4;
INSERT INTO diaries (title, body) VALUES ("survey", "will start groonga!");
INSERT INTO diaries (title, body) VALUES ("groonga (1)", "starting groonga...");
INSERT INTO diaries (title, body) VALUES ("groonga (2)", "started groonga.");
SELECT * FROM diaries WHERE MATCH(body) AGAINST("starting");
id	title	body
2	groonga (1)	starting groonga...
FLUSH TABLES;
SELECT * FROM diaries WHERE MATCH(body) AGAINST("starting");
ERROR HY000: system call error: No such file or directory: failed to open path: <repair_test.mrn.000010B>
REPAIR TABLE diaries;
Table	Op	Msg_type	Msg_text
repair_test.diaries	repair	Error	system call error: No such file or directory: failed to open path: <repair_test.mrn.000010B>
repair_test.diaries	repair	status	OK
SELECT * FROM diaries;
id	title	body
1	survey	will start groonga!
2	groonga (1)	starting groonga...
3	groonga (2)	started groonga.
SELECT * FROM diaries WHERE MATCH(body) AGAINST("starting");
id	title	body
2	groonga (1)	starting groonga...
DROP TABLE diaries;
DROP DATABASE repair_test;
USE test;
