Snowddl - Alter statement Issue #39
Replies: 2 comments 6 replies
-
As part of this above exercise, we have to add new column to existing table. But since above issue was a blocker, new column dint got added to other table . Now , I altered table externally but it does not identify the table. instead it gives me below command - CREATE OR REPLACE TABLE "DB_NAME"."SCHEMA"."TABLE_NAME" |
Beta Was this translation helpful? Give feedback.
-
So what is the specific error message or incorrect state? What goes wrong exactly? Regarding to "CREATE OR REPLACE TABLE", Snowflake supports very limited number of table transformations via ALTER TABLE: https://docs.snowflake.com/en/sql-reference/sql/alter-table-column Everything else requires full table rewrite, which takes form of "CREATE OR REPLACE TABLE" statement. I suspect, manual alter changed the state of table, which can only be repaired by full rewrite. |
Beta Was this translation helpful? Give feedback.
-
ALTER TABLE "DB_NAME"."SCHEMA_NAME"."TABLE_NAME" MODIFY COLUMN "PARTITION" COMMENT 'Project Key /Id';
This statement does not work as expected. So subsequent alter statements on any other table are not executed as well. Do we see any alternative.
Beta Was this translation helpful? Give feedback.
All reactions