Does anyone know a script to get all the table definition of one schema in once?
Thanks!
Lisa
Printable View
Does anyone know a script to get all the table definition of one schema in once?
Thanks!
Lisa
You might be able to use the
fromuser and touser
options of import to get what you want.
you could use dbms_metadata if you are using 9i
select dbms_metadata.get_ddl('TABLE', table_name) from user_tables
The easiest is probably to export the user, ROWS=N, then generate an indexfile using import. (With the right editor, you don't even need the import step.)
I have an old script to dump a user (it goes back to V6), but the above is cleaner and more consistent.