Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Script to drop packages 1

Status
Not open for further replies.

pjeypal

Programmer
Apr 17, 2006
36
US


A simple one.I need a script to drop all packages in a schema where name starts with 'T_%'
 

Try:
Code:
set pages 0 trims on feed off ver off term off
spo drop_pkg.sql
select 'DROP '||'object_type||' '||object_name||';'
  from user_objects where object_type = 'PACKAGE';
spo off
@drop_pkg
[noevil]

----------------------------------------------------------------------------
The person who says it can't be done should not interrupt the person doing it. -- Chinese proverb
 

PS: change to:

Code:
...where object_type LIKE = 'PACKAGE%';




----------------------------------------------------------------------------
The person who says it can't be done should not interrupt the person doing it. -- Chinese proverb
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top