everything is in the question.
I have a table named tableA on which we have indexes and foreign keys and constraints.
I have to modify content in a column called column1. This being a production system, I want to
1) create a copy of tableA called tableA_temp
2) Perform the data change (some concatenation and regexp_replace)
3) Obtain validation that the change is correct
4) rename tableA to tableA_old
4) Rename tableA_temp to tableA.
Once renamed to tableA, would the constraints and indexes apply to the new tableA?
My guess is yes but I would need a little validation.
alter table ... rename column ...commands, and at some point drop the original (now renamed) column. Seems slightly less messy than doing it at table level. – Alex Poole Sep 11 '12 at 17:57