Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support ability to alter schema/database and rename #2226

Closed
mwufigma opened this issue Nov 30, 2023 · 2 comments
Closed

Support ability to alter schema/database and rename #2226

mwufigma opened this issue Nov 30, 2023 · 2 comments
Labels
category:resource feature-request Used to mark issues with provider's missing functionalities resource:schema Issue connected to the snowflake_schema resource

Comments

@mwufigma
Copy link

Terraform CLI and Provider Versions

Terraform CLI version: >= 1.5.0
Snowflake provider version: 0.68.0

Use Cases or Problem Statement

When we try to update the name of a schema in Terraform, it attempts to drop and re-create it. We do not want this behavior and would need it to ALTER SCHEMA RENAME ....

Proposal

Implement something similar to the solution to this issue #891 but for schemas and databases

How much impact is this issue causing?

High

Additional Information

No response

@mwufigma mwufigma added the feature-request Used to mark issues with provider's missing functionalities label Nov 30, 2023
@sfc-gh-asawicki
Copy link
Collaborator

Hey @mwufigma. Thanks for creating the issue.

We are supporting renames for the schema. We changed the schema implementation lately (check https://github.com/Snowflake-Labs/terraform-provider-snowflake/releases/tag/v0.73.0). The rename happens here:

if d.HasChange("name") {
. I have also confirmed that in this test:
func TestAcc_SchemaRename(t *testing.T) {
rename is behaving correctly.

You may be changing another parameter that causes a recreation.

Can you upgrade to the newer provider version first? If this does not help, could you provide the configurations you are using that are causing the issue?

@sfc-gh-asawicki
Copy link
Collaborator

Hey @mwufigma, I will close this issue; please open a new one if you are experiencing problems with renaming in the more recent versions of the provider.

@sfc-gh-jcieslak sfc-gh-jcieslak added category:resource resource:schema Issue connected to the snowflake_schema resource labels May 20, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
category:resource feature-request Used to mark issues with provider's missing functionalities resource:schema Issue connected to the snowflake_schema resource
Projects
None yet
Development

No branches or pull requests

3 participants