terraform-provider-snowflake
terraform-provider-snowflake copied to clipboard
snowflake_table_constraint generating SQL with more optional parameters than specified in the resource
Terraform CLI and Provider Versions
0.87.2
Terraform Configuration
resource "snowflake_table_constraint" "pk_reporting_dim" {
name = "PK_REPORTING_DIM"
type = "PRIMARY KEY"
table_id = snowflake_table.reporting_dim.qualified_name
columns = ["TAGKEY"]
rely = true
}
Expected Behavior
Currently the SQL should only specify optional parameters from resource.
Expected SQL: ALTER TABLE "REPORTING_DIM" ADD CONSTRAINT PK_REPORTING_DIM PRIMARY KEY ("TAGKEY") RELY;
Actual Behavior
Currently the SQL generated will specify more optional parameters than expected.
Generated SQL: ALTER TABLE "REPORTING_DIM" ADD CONSTRAINT PK_REPORTING_DIM PRIMARY KEY ("TAGKEY") DEFERRABLE INITIALLY DEFERRED ENABLE RELY;
Steps to Reproduce
terraform apply
How much impact is this issue causing?
Medium
Logs
No response
Additional Information
No response
Hey @wpl-sf-nbirch. We will handle this topic as part of the resources redesign (https://github.com/Snowflake-Labs/terraform-provider-snowflake/blob/main/ROADMAP.md#supporting-all-snowflake-ga-features).