About sql validator
Catch simple mistakes in SQL before you run it: unclosed quotes, unbalanced brackets, trailing commas and clause problems.
Limits
This is a quick syntax check, not a full database parser. Your database is the final judge, and different engines have different dialects.
A worked example
The query SELECT name, FROM users WHERE (id = 1 is flagged for a trailing comma before FROM and an unclosed bracket. Catching these in advance avoids a round trip to the database, whose own message may be harder to read.
What it does not do
- It does not know your tables or columns.
- It cannot catch dialect differences, such as LIMIT versus TOP.
- It does not check that the query is safe or efficient. Use EXPLAIN for performance.
Strings and comments
The check ignores brackets and keywords inside quoted strings and comments, so a value such as 'Hello (world' does not trigger a false warning.
