Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.misc -> Re: SQL*Plus anyone?
bruce pihlamae <bpihlama_at_nla.gov.au> wrote in article
<32A89A23.599E_at_nla.gov.au>...
> > FOR c1rec IN c1 LOOP
>
> You should define s1rec just after cursor definition
> eg c1rec c1%ROWTYPE;
Not correct - the FOR statement implicit declares the ROWTYPE variable. In
fact, you might get errors, if you try to use an explicit declared
variable.
The error is comming from not being able to access one of the tables in the cursor. The following error, that the C1REC cannot be referered/created because the cursor is in error.
My guess is, that the cursor works allright directly as a select-statement i SQL*Plus, right? Then your problem is your access-right to the table, namely you cannot reference objects through roles from a package/view/procedure. You must have a DIRECT grant of select to be able to do that.
-- // Complete Data Service // Peter H. Larsen // PETLARS_at_IBM.NETReceived on Tue Dec 10 1996 - 00:00:00 CST
![]() |
![]() |