Page 1 of 1

ORA-04043 WHEN USING SYNONYM FOR TYPE OBJECT WORKS FROM SQLPLUS

Posted: Mon 05 May 2008 14:44
by klayme
Hi. We have a problem when using private synonyms to access a type on another schema.
.NET application raises ORA-04043: object TBL_PROPOSALS does not exist. The same statement works ok in sqlplus, or in .NET app when the type used is referenced with the owner instead of the private synonym:

Not working:
Dim objOra As OracleObject
tblProposal = New OracleTable("tbl_Proposals", objConn)
objOra = New OracleObject("obj_Proposals", objConn)

Working ok:
Dim objOra As OracleObject
tblProposal = New OracleTable("typeowner.tbl_Proposals", objConn)
objOra = New OracleObject("typeowner.obj_Proposals", objConn)

Can you please tell us where is the problem? Thank you.

Posted: Mon 05 May 2008 15:17
by Alexey.mdr
We reproduced the problem and now we are fixing it.
Look forward to the next build.

Posted: Tue 06 May 2008 11:13
by Alexey.mdr
Hi!

Could you please try the following lines?
There were no problems detected with OraDirect .NET 4.60.33
and private synonym created as

Code: Select all

CREATE SYNONYM SCHEMA2.SYNONYMNAME for SCHEMA1.OBJECT1
With public synonyms created as

Code: Select all

CREATE PUBLIC SYNONYM SYNONYMNAME for SCHEMA1.OBJECT1
you have to add PUBLIC.

Code: Select all

objOra = New OracleObject("PUBLIC.obj_Proposals", objConn);