-
Notifications
You must be signed in to change notification settings - Fork 422
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 the ability to alter table...rename a column #420
Comments
This would be a great feature. Plus, the ability to change data type would be great too. |
I would like to see this feature released any time soon! |
I would love this functionality too. I imagine the issue is maintaining the column id across each iteration. ie, if you change the name, right now TF is going to treat it like a drop and add. However, if the column had on id field, you could change attributes of it without losing the relationship. The problem with this is that you'd now have a TF field to create with each column that is only valuable occassionally.
Or maybe we pass in a column resource instead of the current structure? Something like:
I'm not sure if the option above is syntactically possible in TF, but something along either line would be very helpful. |
I would love to have this feature. I am new to Go language but I would be happy to collaborate with anyone to implement this feature. |
I'd love to see this one go through. Can we make it happen? |
I am also experiencing issues with this. To add a little more color, the problem extends beyond not being able to alter a column in place, as trying to rename a column can also cause unintended changes to other columns that are not being modified. For instance, let a resource be created as follows:
Now let column
Terraform will drop I like @mddataminr's suggestions, particularly the first one. Similar to @sagar-raythatha I don't have Go experience but would be contribute in any way I can. |
I would like to see this feature added. If you have a table with a single column and then try to rename the column, terraform apply will fail with an error because it attempts to drop the column which is not allowed when it is the only column in the table. |
schema evolution strategy would be highly appreciated
|
I noticed similar behaviour like @elikschultz describe. I have table definition with sth like
and after each
|
Please add this feature, would be extremely helpful! |
+1; please add this feature -- it would be really helpful! |
+1, having the same issue as @jandanecki. Btw, @jandanecki how are you handling this issue in your terraform code, I have a lot of tables and this behavior overwhelms the output of my |
Bringing this thread back to attention—can this be resolved quickly? We're facing numerous issues due to the lack of this capability. |
Hey @reachoutbud. We are aware this is still a valid problem and it is on our roadmap: https://github.com/Snowflake-Labs/terraform-provider-snowflake/blob/main/ROADMAP.md#support-object-renaming-properly. |
@sfc-gh-asawicki |
@reachoutbud we do not have any specific date that we can share at the moment. |
Hi all 👋 |
Test cases for changes in lists and sets. From the given time, I only went through essential cases that consisted of: - Ignoring the order of list items after creation. - Having the ability to update an item while ignoring the order. For the testing, I created a test resource because currently, we don't have anything to test more complex examples of certain resource behaviors (temporary providers we create for custom diff testing are not sufficient in this case). The resource is only added to the resource list whenever a special env is set (we could remove it entirely and leave some documentation in the resource file (and acc test file) on how to prepare for the tests). The imitation of external storage was done by creating a struct and its global instance (some of the things needed to be exported since external changes tested in acceptance tests needed to access those). Certain resource fields were researched to test different approaches, each is described in the implementation file. Also added an assert on lists/sets that is able to assert items in order independent manner (it was needed for the tests of the proposals). > Note: Only lists were tested, because there was no major issue with them in current resources. For the lists the following issues were addressed: #420, #753 ## Next pr - Apply (parameterized tests in object renaming test cases) #3130 (comment)
As a data modeler, I need to rename a column. I would like to use the snowflake_table resource to support this action
From pure-DDL perspective, it would like this:
alter table mydb.myschema.mytbl rename column col1 to column1;
to be supported with a ne property called OLD_NAME in the nested schema for column (as such):
The text was updated successfully, but these errors were encountered: