By submitting your email address, you agree to receive emails regarding relevant topic offers from TechTarget and its partners. You can withdraw your consent at any time. Contact TechTarget at 275 Grove Street, Newton, MA.
ALTER TABLE table_name ADD (column_name datatype);I'm not sure why you do not want to use the above command as it works great! However, you have another option at your disposal with slightly more work. This option involves copying the data to another table, re-creating the original table and moving the data back:
CREATE TABLE my_table_interim AS SELECT * FROM my_table; DROP TABLE my_table; CREATE TABE my_table ( ....); INSERT INTO my_table (col1, col2 ...) SELECT col1, col2, ... FROM my_table_interim; DROP TABLE my_table_interim;In the INSERT statement above, you will have to explictily denote which columns you are copying from the interim table to the destination table since both tables will have a different number of columns.
Dig Deeper on Oracle database design and architecture
Have a question for an expert?
Please add a title for your question
Get answers from a TechTarget expert on whatever's puzzling you.