File tree Expand file tree Collapse file tree 3 files changed +21
-1
lines changed Expand file tree Collapse file tree 3 files changed +21
-1
lines changed Original file line number Diff line number Diff line change @@ -1119,7 +1119,7 @@ impl<'a> Tokenizer<'a> {
11191119 {
11201120 s. push ( '.' ) ;
11211121 chars. next ( ) ;
1122- } else if s. is_empty ( ) {
1122+ } else if ! s. is_empty ( ) {
11231123 // Number might be part of period separated construct. Keep the period for next token
11241124 // e.g. a-12.b
11251125 return Ok ( Some ( Token :: Number ( s, false ) ) ) ;
Original file line number Diff line number Diff line change @@ -2232,3 +2232,12 @@ fn test_any_value() {
22322232 bigquery_and_generic ( ) . verified_expr ( "ANY_VALUE(fruit HAVING MAX sold)" ) ;
22332233 bigquery_and_generic ( ) . verified_expr ( "ANY_VALUE(fruit HAVING MIN sold)" ) ;
22342234}
2235+
2236+ #[ test]
2237+ fn test_err ( ) {
2238+ let res = bigquery ( ) . parse_sql_statements ( "SELECT * FROM bq-dwh-prod-327613.xyz" ) ;
2239+ print ! ( "{:?}" , res) ;
2240+
2241+ let res = bigquery ( ) . parse_sql_statements ( "SELECT xy-12.z FROM bq-dwh-prod-327613.xyz" ) ;
2242+ print ! ( "{:?}" , res) ;
2243+ }
Original file line number Diff line number Diff line change @@ -313,3 +313,14 @@ fn parse_databricks_struct_function() {
313313 } )
314314 ) ;
315315}
316+
317+ // #[test]
318+ // fn test_err() {
319+ // let res = databricks().parse_sql_statements("SELECT *
320+ // FROM
321+ // datamart_att.att_user_features_daily_v1
322+ // WHERE
323+ // period <= struct(x).y");
324+
325+ // print!("{:?}", res);
326+ // }
You can’t perform that action at this time.
0 commit comments