Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> Re: Confused with bind variables
Syltrem wrote:
> Again I forgot!
>
> This is on Oracle 816
>
> Thanks
>
> --
>
> Syltrem
> http://pages.infinit.net/syltrem (OpenVMS related web site - en français)
> To reply to myself directly, remove zulu from my address
>
> "Syltrem" <syltremzulu_at_videotron.ca> a écrit dans le message de news: ...
> > declare
> > STATUS number;
> > begin
> > RENCS_ARC.ARCHIVE('GL_POSTINGS', 'A_GL_POSTINGS', '6', 36, :STATUS);
> > END;
> > /
> >
> > SP2-0552: Bind variable "STATUS" not declared.
> >
> > ???
> >
> > I don't get it.
> >
> > Isn't the STATUS variable I declare, a bind variable?
> >
> > Confused.
> >
> > Thanks for helping
> >
> > --
> >
> > Syltrem
> > http://pages.infinit.net/syltrem (OpenVMS related web site - en français)
> > To reply to myself directly, remove zulu from my address
> >
> >
> >
You can't use a bind variable in the manner you are attempting. Consider this instead:
x := 'ABC';
EXECUTE IMMEDIATE 'TRUNCATE TABLE :TABNAME'
USING x;
Daniel Morgan Received on Fri Aug 23 2002 - 16:48:27 CDT