Skip to Main Content

SQL & PL/SQL

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

ORA 28267: invalid namespace value executing sql on table in different db

658396Sep 5 2008 — edited Dec 21 2008
I have a procedure in a package, in which I need to execute a select statement on a different db, for which I created a db link. Executing this in my IDE (sqldeveloper) works fine and returns expected value. But when I invoke this package via jdbc, it fails with the above sql exception. Looking at the error documentation/help was not useful so far.

The statement looks like this:
srcSqlstmt := 'select count(*) from ' || srctabname || '@' || srcDBName || ' where ' || columnname || ' is not null';

where srcDBName is a database link that I created, to another database which contains srctabName.

Appreciate any tips on resolving this. Thanks !
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Oct 6 2008
Added on Sep 5 2008
3 comments
621 views