SGA-3801 Added support for concatenating string literals saperated by space in mySQL

This commit is contained in:
Etgar Perets 2025-08-17 11:08:03 +03:00
parent b660a3b1ea
commit 04c8f9bb1d
4 changed files with 61 additions and 2 deletions

View file

@ -4245,3 +4245,12 @@ fn test_create_index_options() {
"CREATE INDEX idx_name ON t(c1, c2) USING BTREE LOCK = EXCLUSIVE ALGORITHM = DEFAULT",
);
}
#[test]
fn parse_adjacent_string_literal_concatenation() {
let sql = r#"SELECT 'M' "y" 'S' "q" 'l'"#;
mysql().one_statement_parses_to(sql, r"SELECT 'MySql'");
let sql = "SELECT * FROM t WHERE col = 'Hello' \n ' ' \t 'World!'";
mysql().one_statement_parses_to(sql, r"SELECT * FROM t WHERE col = 'Hello World!'");
}