mirror of
https://github.com/apache/datafusion-sqlparser-rs.git
synced 2025-11-01 15:44:14 +00:00
Parser::parse_sql() can now parse a semicolon-separated list of
statements, returning them in a Vec<SQLStatement>.
To support this we:
- Move handling of inter-statement tokens from the end of individual
statement parsers (`parse_select` and `parse_delete`; this was not
implemented for other top-level statements) to the common
statement-list parsing code (`parse_sql`);
- Change the "Unexpected token at end of ..." error, which didn't have
tests and prevented us from parsing successive statements ->
"Expected end of statement" (i.e. a delimiter - currently only ";" -
or the EOF);
- Add PartialEq on ParserError to be able to assert_eq!() that parsing
statements that do not terminate properly returns an expected error.
|
||
|---|---|---|
| .. | ||
| sqlparser_ansi.rs | ||
| sqlparser_generic.rs | ||
| sqlparser_postgres.rs | ||