Diagnostic tool for checking alternate index paths.
Section: Verify usage
Test with FORCE INDEX
sql
sql
SELECT id
FROM orders FORCE INDEX (idx_orders_status_created_at)
WHERE status = 'paid'
ORDER BY created_at DESC
LIMIT 50;Explanation
Useful for testing, but avoid relying on it as the first fix for poor design.
Learn the surrounding workflow
Compare similar commands or jump into common fixes when this command is part of a bigger troubleshooting path.
Related commands
Same sheet · prioritizing Verify usage
Refresh table statistics
Help the optimizer make better choices after major data changes.
Create an invisible index
Test an index without making it visible to the optimizer by default.