SOAR

A command-line SQL optimizer and rewriter for MySQL-syntax SQL, built on heuristic rules and detailed EXPLAIN interpretation.


About

SOAR (SQL Optimizer And Rewriter) is an automated command-line tool, developed and maintained by Xiaomi’s database team, that analyzes and rewrites SQL written in the MySQL dialect. It currently targets MySQL and MySQL-compatible SQL syntax.

Its heuristic rule engine flags and suggests fixes for statement-level issues across SELECT, INSERT, UPDATE, and DELETE queries, including multi-column index opportunities for complex queries. It also gives a detailed, human-readable interpretation of EXPLAIN output, can fingerprint, compress, and beautify SQL text, merges multiple ALTER TABLE statements against the same table, and lets users define their own rewrite rules. SOAR is written in Go and released under the Apache License 2.0.

Category Software & Tools
Subcategory Testing & Benchmarking
Repository XiaoMi/soar ↗
✎ Suggest an update

Community feedback

This space is for grounded, evaluable experience — versions used, environments, what you measured or observed, and how it behaves alongside other software. General impressions without supporting detail may be removed. Sign in to write one; posts are tied to a verified identity, not anonymous.