Take the 2-minute tour ×
Database Administrators Stack Exchange is a question and answer site for database professionals who wish to improve their database skills and learn from others in the community. It's 100% free, no registration required.

In Oracle 10g, how do I delete all the types owned by a specific user? This is the view that gives me the types I want to drop:SELECT type_name FROM user_types;

share|improve this question

1 Answer 1

Use a query to generate a drop type script [in SQL Plus]:

set lines 132
set head off
set pages 0

spool drop_types.sql

select 'drop type '||type_name||';'
from user_types;

spool off

Then execute the script in SQL Plus:

@drop_types.sql
share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.