0

I want to create a new stored procedure but I got this error:

00955. 00000 -  "name is already used by an existing object"

The problem is I don't remember to have created an object with this name and, now, I would like to remove it (don't worry, it's not on my production database).

How can I find the type of this object in order to drop it correctly?

0

The DBA_OBJECTS view describes all the objects in the database. In it, you can find, by instance, the name of an object, its owner or its type.

Example:

SELECT owner, object_name, object_type FROM dba_objects WHERE object_name = 'MY_OBJECT'; -- Be careful, the name is case sensitive.

OWNER               OBJECT_NAME         OBJECT_TYPE 
------------------- ------------------- -------------------
MY_USER             MY_OBJECT           PROCEDURE

Now, you can easily drop it:

DROP PROCEDURE MY_OBJECT;

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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