what command is used to create a table by copying the
structure of another table including constraints ?
Answer Posted / selvaraj v , anna univ coe
To Use same database :
======================
CREATE TABLE NEW_TBLNAME AS SELECT * FROM OLD_TBLNAME WHERE
1=2;
EXAMPLE :
---------
CREATE Emp_tbl2 AS SELECT * FROM Employee_Tbl1 WHERE 1=2;
Table creation From One USER To Another USER :
======================================================
COPY FROM coeot1a2/coeot1a2@coeau TO scott/tiger@server1
CREATE s11 USING SELECT * FROM major_List;
coeot1a2 ----> USER NAME
coeot1a2 ----> PASSWORD
coeau -------> SERVER NAME
scott -------> Another USER NAME
tiger -------> Another User PASSWORD
server1 -----> Another SERVER NAME
| Is This Answer Correct ? | 1 Yes | 6 No |
Post New Answer View All Answers
differentiate between float and double. : Sql dba
What language is oracle sql developer?
What is difference sql and mysql?
How do you optimize a query?
Difference between global and parameter variables?
what are date and time functions in mysql? : Sql dba
Do stored procedures prevent sql injection?
Does access use sql?
What are the key differences between SQL and PL SQL?
what is the difference between truncate and drop statements? : Sql dba
What is meant by user defined function?
What is the command used to fetch the first 5 characters of a string?
Is it possible to include an insert statement on the same table to which the trigger is assigned?
What are different types of indexes?
how to shut down the server with 'mysqladmin'? : Sql dba