The index key (time desc, username, name, facility, event, sector, item, details) could potentially be 32867 bytes long. However, an index key must be less than 1/2 the page size, according to the "Page size and key size" topic at That is, your new index key is too big.

With the subquery-based approach, your covering index key would be only 20 bytes long:

CREATE INDEX log_index ON system_log (time DESC, id);

Reply via email to