Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> Re: Drop all the objects inside a tablespace.
It is possible to do, but, if there are other tables w/ foreign keys
pointing to the tables you want to drop, you will need to drop the
foreign keys. You can write sql to create the sql to do it for you.
Like the following:
select 'drop table ',owner||'.'||table_name, ';'
from dba_segments
where tablespace_name = 'YOUR_TABLESPACE_NAME'
and segment_type = 'TABLE'
;
Check the syntax and the segment_type value, but, run that in sqlplus or worksheet, then run the output.
HTH,
Pete's
guptap_at_synygy.com (Prabuddha) wrote in message news:<567752f5.0108220628.260d53f4_at_posting.google.com>...
> Hi All,
> I want to drop all the tables inside a tablespace without dropping the
> tablespace.So that after dropping the old tables,I can create new
> tables inside that tablespace. Is there a way?
>
> Thanks in advance.
> Prabuddha
Received on Wed Aug 22 2001 - 15:48:24 CDT