Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.server -> Re: Creating a copy of a partitioned table without the data...
"RaviAlluru" <ravi.alluru_at_gmail.com> wrote in message
news:1120507146.455202.213150_at_z14g2000cwz.googlegroups.com...
> Hello All,
> Is there a quick way to create an empty table having the same
> structure as an existing partitioned table (minus the data):
>
> i.e sort of do this
>
> CREATE TABLE BCK_A_PART AS SELECT * FROM A_PART
> WHERE 1=2;
>
> where A_PART is the partitioned table and BCK_A_PART is the copy (minus
> data).
>
> PS:The above command just created the table without the partition.
>
>
> Also is there a dictionary view or table to extract DDL for a users
> objects ?
>
>
> Thanks
>
> Ravi Alluru
>
No totally simple way, but you could use
dbms_metadata.get_ddl to get the SQL
as a CLOB and then modify and run it.
-- Regards Jonathan Lewis http://www.jlcomp.demon.co.uk/faq/ind_faq.html The Co-operative Oracle Users' FAQ http://www.jlcomp.demon.co.uk/appearances.html Public Appearances - schedule updated June 22nd 2005Received on Mon Jul 04 2005 - 15:19:46 CDT
![]() |
![]() |