Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.misc -> Re: Drop tables at once
> > Is there a way to drop all tables, indexes etc at once? I
> now have to
> > do it either manually following the right order so the error
> message
> > (ORA-02449: unique/primary keys in table referenced by
> foreign keys)
> > doesn't appear
> > or via the Schema Manager (removing table one by one).
> Several suggestions:
> - if you have the right to do this and the script to
> recreate the database, you could do a "drop database"
> (it may be too radical);
> - otherwise, use the great tool called "Toad" (Tool for
> Oracle Application Developers, freeware version available
> from www.toadsoft.com): it can automatically create a
> scripts to recreate all the tables of a database
> (in the right sequence of constraints). You can also
> modify the script to keep only the DROP TABLE statements.
> Opinion: Schema Manager and interactive tools are great,
> but you still need to work with scripts to work fast and
> be able to recreate what you have done. Toad is giving you
> a lot of help to reach this.
> Hope this helps
>
Or if the schema-user is not neccessary anymore then
drop user <username> cascade
This will delete every object that owns the user <username> and it follows every integrity rule.
Regards
Nicolas Bronke
Received on Tue Oct 12 1999 - 08:30:13 CDT
![]() |
![]() |