- How to create a new table based on the existing table in another schema without data i.e., only the structure of the table?
SYNTAX:
create column table "New_Schema_Name"."New_Table_Name" like "Old_Schema_Name"."Old_Table_Name";
CODE:
create column table "KABIL"."EMPLOYEE_SAMPLE" like "KABIL_PRACTICE"."EMPLOYEE_SAMPLE";
RESULT:
2. How to create a new table based on the existing table in another schema with data?
SYNTAX:
create column table "New_Schema_Name"."New_Table_Name" as ( select * from "Old_Schema_Name"."Old_Table_Name");
CODE:
create column table "KABIL"."EMPLOYEE_SAMPLE" as ( select * from "KABIL_PRACTICE"."EMPLOYEE_SAMPLE");
RESULT: