Database

How can I create a copy of an Oracle table without copying the data?

steloflute 2013. 4. 8. 23:30

http://stackoverflow.com/questions/233870/how-can-i-create-a-copy-of-an-oracle-table-without-copying-the-data

 

I know the statement:

create table xyz_new as select * from xyz;

Which copies the structure and the data, but what if I just want the structure?

 

Just use a where clause that won't select any rows:

create table xyz_new as select * from xyz where 1=0;