Commit eaeee57
Task LAV-2094: CREATE OR REPLACE VIEW (cols) COPY GRANTS parses; SHOW DYNAMIC TABLES
* Task LAV-2094: VIEW COPY GRANTS after column list; canonical SHOW DYNAMIC TABLES text
- Parse COPY GRANTS both before and after the view column list.
- Render SHOW DYNAMIC TABLES .text in real Snowflake's canonical form via a
shared renderer also used by GET_DDL.
- Add compat test (real-SF snapshot) for a column-list view with COPY GRANTS
after the columns: the SELECT grant survives CREATE OR REPLACE.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
* Task LAV-2094: SHOW DYNAMIC TABLES canonical re-serialized text; frozen_where/configured_refresh_mode columns; real-name TARGET_LAG error
* Task LAV-2094: reconcile SHOW DYNAMIC TABLES text with main's CREATE OR ALTER tests
Rebasing onto newer main pulled in LAV-385's CREATE OR ALTER DYNAMIC TABLE
tests, whose snapshots were recorded while the shared
_add_show_dynamic_table_transformers helper still masked the `text` column.
Un-masking `text` in the shared helper (this task's AC 3) inadvertently
un-masked those tests too, which are about in-place ALTER semantics, not text
rendering, and are outside AC 3's un-mask scope. Restore their original masked
behaviour with an inline text mask on the five that SHOW a text row
(creates, in_place, comment_reset, property_changes, transient).
Also append the frozen_where / configured_refresh_mode columns to the dynamic
iceberg table's SHOW snapshot row so it matches the emulator's SHOW shape
(both deterministic: null and the INCREMENTAL refresh_mode reference).
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
* Task LAV-2094: don't fire the missing-database gate on CTE aliases in DDL bodies
TestAcc_GrantPrivilegesToShare_OnDynamicTable failed at step 1/2: the
terraform provider creates the dynamic table with a `WITH temp AS (…)
SELECT … FROM temp` body and no current database, and the identifier-check
gate treated the 1-part CTE alias `temp` as a schema object (DdlStrict fires
090105/090106 on bare 1-part relations), rejecting the CREATE.
CTE aliases are query-local names, never schema objects — real Snowflake never
fires the missing-context gate on them. Collect the statement's CTE aliases and
skip any bare 1-part relation that resolves to one. Under-qualified *real*
relations in a table body still fire (a table's body resolves against the
session, unlike a view's), so this exempts only the CTE alias itself.
Verified end-to-end: both DoD terraform tests
(TestAcc_View_CheckGrantsAfterRecreation, TestAcc_GrantPrivilegesToShare_OnDynamicTable)
now pass locally against the emulator.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
---------
Co-authored-by: Wojciech Padło <wojciech.padlo@localstack.cloud>
Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>text is rendered in real Snowflake's canonical form (#2555)1 parent 6e67d3f commit eaeee57
1 file changed
Lines changed: 5 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
7335 | 7335 | | |
7336 | 7336 | | |
7337 | 7337 | | |
7338 | | - | |
| 7338 | + | |
7339 | 7339 | | |
7340 | 7340 | | |
7341 | 7341 | | |
| 7342 | + | |
| 7343 | + | |
| 7344 | + | |
| 7345 | + | |
7342 | 7346 | | |
7343 | 7347 | | |
7344 | 7348 | | |
| |||
0 commit comments