As described here I have a corrupt table which I cannot repair.
Table name is
nextcloud.oc_systemtag_object_mapping
Can I somehow delete the table and let it be rebuild?
I tried
occ recognize:reset-tags
But it does not do anything, even after hours.
Trying to select everything from the table leads to an error:
ERROR 1034 (HY000): Index for table ‘oc_systemtag_object_mapping’ is corrupt; try to repair it
There is another error in the logs of the db, but I think its not relevant:
2024-08-08 13:13:29 793 [ERROR] Incorrect definition of table mysql.column_stats: expected column 'histogram' at position 10 to have type longblob, found type varbinary(255).
2024-08-08 13:13:29 793 [ERROR] Incorrect definition of table mysql.column_stats: expected column 'hist_type' at position 9 to have type enum('SINGLE_PREC_HB','DOUBLE_PREC_HB','JSON_HB'), found type enum('SINGLE_PREC_HB','DOUBLE_PREC_HB').
2024-08-08 13:13:29 793 [ERROR] Incorrect definition of table mysql.column_stats: expected column 'histogram' at position 10 to have type longblob, found type varbinary(255).
This is the mysql code I created from it. I am unsure how to create the index and can not find anything about it in php tutorials. Can someone jump in and tell me how to create the index properly?
CREATE table nextcloud.oc_systemtag_object_mapping (
objectid VARCHAR(64) NOT NULL ,
objecttype VARCHAR(64) NOT NULL,
systemtagid INT,
PRIMARY KEY(objecttype, objectid, systemtagid)
);
CREATE INDEX ??? ON nextcloud.oc_systemtag_object_mapping(???)