Home » SQL & PL/SQL » SQL & PL/SQL » Create table from existing table
Create table from existing table [message #822] Wed, 06 March 2002 05:26 Go to next message
Saravanan Veerappan
Messages: 1
Registered: March 2002
Junior Member
I need to create a new table as same table structure as existing table with constraints.Then i need to drop existing table. When i use create table tableA as select * from tableB, it creates table without copying constraints.

I appreciate your help.
Re: Create table from existing table [message #823 is a reply to message #822] Wed, 06 March 2002 05:54 Go to previous message
pratap kumar tripathy
Messages: 660
Registered: January 2002
Senior Member
u have to create constraints manually. if u r not sure what are the contraints then see user_constraints and user_cons_columns, which keeps information about the constraints
Previous Topic: Sequence numbers in SQL or Stored Procedure
Next Topic: how to generate random records
Goto Forum:
  


Current Time: Wed Apr 17 21:56:29 CDT 2024