Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.misc -> Re: Using host variables with cursors
try declaring the variable first:
variable table_name varchar2(60)
Blasting Bubbles wrote:
>
> I'm trying to use a cursor like this...
>
> Exec sql declare cursor for select * from :table_name;
>
> but it gives me an error at :table_name. Is there a reason that I can't use
> a variable here? Is there another solution?
>
> BB
Received on Sat Feb 23 2002 - 22:14:43 CST