what command is used to create a table by copying the
structure of another table including constraints ?
Answer Posted / a.jyothsna
I know copying the structure of one table but not the
constraints also:
create table newtablename as
select * from oldtablename;
with the above query total data will also be copied.
But to copy only the structure.
create table newtablename as
select * from oldtablename
where 1=2;
Is This Answer Correct ? | 20 Yes | 6 No |
Post New Answer View All Answers
What are the advantages of stored procedure?
Which command is used to delete a package?
What is user in sql?
List and explain the different types of join clauses supported in ansi-standard sql?
What is sql in java?
Can cursors be part of a trigger body?
What is union, minus and interact commands?
what is union, minus and interact commands? : Sql dba
Mention what plvcmt and plvrb does in pl/sql?
What are the constraints available in sql?
What is denormalization in a database?
Can we edit a view in sql?
What is raid? How does it help storage of databases?
what is the difference between mysql_fetch_object and mysql_fetch_array? : Sql dba
What is sql not null constraint?