Oracle SQL Error: ORA-04052 error occurred when looking up remote object (ora-604/ora-2019)

Oracle: Trying to use a package via db-link ends in a ORA-04052 !

Deutsch/German ORA-04052 Error

ORA-04052: Fehler beim Aufsuchen von Fern-Objekt PUBLIC.UITL_PA@ORA-PRODUCTION
ORA-00604: Fehler auf rekursiver SQL-Ebene 1
ORA-02019: Verbindungsbeschreibung für Fern-Datenbank nicht gefunden

Englisch ORA-04052 Error

ORA-04052: error occurred when looking up remote object PUBLIC.UITL_PA@ORA-PRODUCTION
Cause: An error has occurred when trying to look up a remote object.
ORA-00604: error occurred at recursive SQL level 1
ORA-02019: connection description for remote database not found


Solution:
Mostly this error occurs on invalid TNS Service name or the service name might be missing from the tnsnames.ora
When using a DB-LINK take care of your clean TNS Names!
For example:
create public synonym UTIL_PA for UTIL_PA@ORA-PRODUCTION;
is not the same as:
create public synonym UTIL_PA for UTIL_PA@ORA-PRODUCTION.WORLD;

So watch your tnsnames when using packages via db-links.
When using following tnsnames.ora example:
ORA-PRODUCTION.WORLD=
(DESCRIPTION =
(ADDRESS =
(PROTOCOL = TCP)
(Host = something.ora.com)
(Port = 1521)
)
(CONNECT_DATA =
(SERVICE_NAME = ORA-PRODUCTION.world)
(GLOBAL_NAME = ORA-PRODUCTION.world )
)
)

then u have to use @ORA-PRODUCTION.WORLD for the db-link statements!
That’s it. It’s simple but stupid …

3 thoughts on “Oracle SQL Error: ORA-04052 error occurred when looking up remote object (ora-604/ora-2019)”

  1. Hi there,I read your blogs named “Oracle SQL Error: ORA-04052 error occurred when looking up remote object (ora-604/ora-2019) » SERPland” on a regular basis.Your humoristic style is witty, keep up the good work! And you can look our website about جماهير الاهلى.

  2. Pingback: Ora-00604 Error Occurred At Recursive Sql – whatleycrew.com

Leave a Comment

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Scroll to Top