File tree 3 files changed +44
-4
lines changed
test/fixtures/dialects/snowflake
3 files changed +44
-4
lines changed Original file line number Diff line number Diff line change 360
360
type = "copy_on_error_option" ,
361
361
),
362
362
DynamicTableLagIntervalSegment = RegexParser (
363
- r"'((DOWNSTREAM)|([1-9]\d*\s+(?:SECOND|MINUTE|HOUR|DAY)S?)) '" ,
363
+ r"DYNAMIC|'.* '" ,
364
364
LiteralSegment ,
365
365
type = "dynamic_table_lag_interval_segment" ,
366
366
),
Original file line number Diff line number Diff line change @@ -180,12 +180,18 @@ WAREHOUSE = mywh
180
180
AS
181
181
SELECT * FROM my_table;
182
182
183
- CREATE OR REPLACE DYNAMIC TABLE DT_WITH_MULTIPLE_DAYS_LAG
183
+ CREATE OR REPLACE DYNAMIC TABLE my_table
184
184
TARGET_LAG = ' 5 days'
185
185
WAREHOUSE = mywh
186
186
AS
187
187
SELECT * FROM my_table;
188
188
189
+ CREATE OR REPLACE DYNAMIC TABLE my_table
190
+ TARGET_LAG = ' ${my_time_variable}'
191
+ WAREHOUSE = mywh
192
+ AS
193
+ SELECT * FROM my_table;
194
+
189
195
CREATE OR REPLACE TABLE IF NOT EXISTS EXAMPLE_TABLE_WITH_RLS (
190
196
EXAMPLE VARCHAR
191
197
) WITH ROW ACCESS POLICY my_db .my_schema .rls_policy ON (EXAMPLE);
Original file line number Diff line number Diff line change 3
3
# computed by SQLFluff when running the tests. Please run
4
4
# `python test/generate_parse_fixture_yml.py` to generate them after adding or
5
5
# altering SQL files.
6
- _hash : c533f7884aa98a0aa3e740d7dd0250b86ba138c752fcf90e018fb8e036e5b306
6
+ _hash : dd2e987190b52eebc6a01f5f6760d192348c04857db1463679286f311412e4bf
7
7
file :
8
8
- statement :
9
9
create_table_statement :
@@ -1459,7 +1459,7 @@ file:
1459
1459
- keyword : DYNAMIC
1460
1460
- keyword : TABLE
1461
1461
- table_reference :
1462
- naked_identifier : DT_WITH_MULTIPLE_DAYS_LAG
1462
+ naked_identifier : my_table
1463
1463
- keyword : TARGET_LAG
1464
1464
- comparison_operator :
1465
1465
raw_comparison_operator : ' ='
@@ -1485,6 +1485,40 @@ file:
1485
1485
table_reference :
1486
1486
naked_identifier : my_table
1487
1487
- statement_terminator : ;
1488
+ - statement :
1489
+ create_table_statement :
1490
+ - keyword : CREATE
1491
+ - keyword : OR
1492
+ - keyword : REPLACE
1493
+ - keyword : DYNAMIC
1494
+ - keyword : TABLE
1495
+ - table_reference :
1496
+ naked_identifier : my_table
1497
+ - keyword : TARGET_LAG
1498
+ - comparison_operator :
1499
+ raw_comparison_operator : ' ='
1500
+ - dynamic_table_lag_interval_segment : " '${my_time_variable}'"
1501
+ - keyword : WAREHOUSE
1502
+ - comparison_operator :
1503
+ raw_comparison_operator : ' ='
1504
+ - object_reference :
1505
+ naked_identifier : mywh
1506
+ - keyword : AS
1507
+ - select_statement :
1508
+ select_clause :
1509
+ keyword : SELECT
1510
+ select_clause_element :
1511
+ wildcard_expression :
1512
+ wildcard_identifier :
1513
+ star : ' *'
1514
+ from_clause :
1515
+ keyword : FROM
1516
+ from_expression :
1517
+ from_expression_element :
1518
+ table_expression :
1519
+ table_reference :
1520
+ naked_identifier : my_table
1521
+ - statement_terminator : ;
1488
1522
- statement :
1489
1523
create_table_statement :
1490
1524
- keyword : CREATE
You can’t perform that action at this time.
0 commit comments