I faced this situation: Need to move tables from one instance to another instance in Oracle applications. I just need to extract create table definitions, so that I can execute those create statements in another instance.
Script:
SELECT DBMS_METADATA.GET_DDL('TABLE',u.table_name)
FROM ALL_TABLES u
where u.table_name like 'XX_TABLE_NAME'
dbms_metadata package helps us to get the create table definition. You can use all_tables or user_tables to get the table name details.
Usage: Move table definitions from one instance to another instance.
Leave a comment