Fix immediate insert subquery (#4833)

This commit is contained in:
Mees Delzenne 2024-09-19 11:36:18 +02:00 committed by GitHub
parent e0f357c18a
commit 19dc7a3ac7
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 7 additions and 0 deletions

View file

@ -288,6 +288,7 @@ impl Parser<'_> {
t!("RETURN") t!("RETURN")
| t!("SELECT") | t!("SELECT")
| t!("CREATE") | t!("CREATE")
| t!("INSERT")
| t!("UPSERT") | t!("UPSERT")
| t!("UPDATE") | t!("UPDATE")
| t!("DELETE") | t!("DELETE")

View file

@ -106,3 +106,9 @@ fn escaped_params_backtick() {
) )
.unwrap(); .unwrap();
} }
#[test]
fn parse_immediate_insert_subquery() {
let res =
test_parse!(parse_query, r#"LET $insert = INSERT INTO t (SELECT true FROM 1);"#).unwrap();
}