Created
December 19, 2020 02:15
-
-
Save luizvaz/068d953cac8bea10e0bc6d5b89790e7d to your computer and use it in GitHub Desktop.
Oracle Table DDL
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
SET LONG 20000 LONGCHUNKSIZE 20000 PAGESIZE 0 LINESIZE 1000 FEEDBACK OFF VERIFY OFF TRIMSPOOL ON | |
BEGIN | |
DBMS_METADATA.set_transform_param (DBMS_METADATA.session_transform, 'SQLTERMINATOR', true); | |
DBMS_METADATA.set_transform_param (DBMS_METADATA.session_transform, 'PRETTY', true); | |
-- Uncomment the following lines if you need them. | |
--DBMS_METADATA.set_transform_param (DBMS_METADATA.session_transform, 'SEGMENT_ATTRIBUTES', false); | |
--DBMS_METADATA.set_transform_param (DBMS_METADATA.session_transform, 'STORAGE', false); | |
END; | |
/ | |
SELECT DBMS_METADATA.get_ddl ('TABLE', table_name, owner) | |
FROM all_tables | |
WHERE owner = UPPER('OWNER') | |
AND table_name = UPPER('TABLE_NAME'); | |
SET PAGESIZE 14 LINESIZE 100 FEEDBACK ON VERIFY ON | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment