Skip to content

Commit 60df756

Browse files
author
Roman Borschel
committed
wip
1 parent 62495f2 commit 60df756

File tree

2 files changed

+10
-1
lines changed

2 files changed

+10
-1
lines changed

src/dialect/snowflake.rs

+4-1
Original file line numberDiff line numberDiff line change
@@ -1014,6 +1014,7 @@ fn parse_session_options(
10141014
let empty = String::new;
10151015
loop {
10161016
match parser.next_token().token {
1017+
Token::SemiColon => break,
10171018
Token::Comma => continue,
10181019
Token::Word(key) => {
10191020
if set {
@@ -1027,7 +1028,9 @@ fn parse_session_options(
10271028
});
10281029
}
10291030
}
1030-
_ => {
1031+
t => {
1032+
println!("> NEXT TOKEN {:?}", t);
1033+
println!("> PEEK TOKEN {:?}", parser.peek_token().token);
10311034
if parser.peek_token().token == Token::EOF {
10321035
break;
10331036
}

tests/sqlparser_snowflake.rs

+6
Original file line numberDiff line numberDiff line change
@@ -3505,3 +3505,9 @@ fn test_alter_session() {
35053505
);
35063506
snowflake().one_statement_parses_to("ALTER SESSION UNSET a\nB", "ALTER SESSION UNSET a, B");
35073507
}
3508+
3509+
#[test]
3510+
fn voodoo() {
3511+
let res = snowflake().parse_sql_statements("ALTER SESSION SET QUERY_TAG='hello'; SELECT 42");
3512+
println!("{:?}", res);
3513+
}

0 commit comments

Comments
 (0)