Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> Re: Drop table in sql
Hi
Connected as the table owner, run the following from SQL*Plus:
SPOOL drop.sql
SELECT 'DROP TABLE ' || TABLE_NAME || ';' FROM USER_TABLES; SPOOL OFF Remove the odd header line from the generated script and run using @drop.sql from SQL*Plus.
You may have to run this script several times if you have foreign key constraints on some tables...
Hope this helps
Andreas
Cuong Quyen Truong <jackt_at_cse.unsw.EDU.AU> wrote in article
<Pine.OSF.3.95.970918192949.21195D-100000_at_pipe07.orchestra.cse.unsw.EDU.AU>.
.
>
> Does anyone know how to drop all the tables with one sql sttement.
>
>
Received on Thu Sep 18 1997 - 00:00:00 CDT