Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> Re: pl/sql curser will not select from another schema ????
Anders Hattestad <hattis_at_bigfoot.com> wrote in article
<34200529.285E_at_bigfoot.com>...
> I have a litle problem.
> I'm making a litle sql/pl code. I'm logged on as system with dba privl.
> when the I trie to compaile my code I get a error saying:
> PLS-00201: identifier 'TRAFTEKS.STED_DEFS' must be declared
> CURSOR c1 IS
> select dato from TRAFTEKS.STED_DEFS;
> It works from sql*plus.
> I have looked at Deja News and one person sayd it my be a premision
> problem. Thats not the case here.
You have a permission problem. PL/SQL won't recognize permissions granted via a role. The permission must be granted directly to the user.
Either that or you've overlooked a typo. "TRAFTEKS.STED_DEFS" sure looks like transmission line noise to me. Or a TECO editor command (ha ha-- this is a paraphrase from the tongue-in-cheek article "Real Programmers Don't Use Pascal" written about 12 years ago. Did I just date myself or what?).