Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: Dynamic SQL using INSERT with a predefined query and an id.

Re: Dynamic SQL using INSERT with a predefined query and an id.

From: Brian Tkatch <SPAMBLOCK.Maxwell_Smart_at_ThePentagon.com.SPAMBLOCK>
Date: Wed, 27 Jun 2001 22:39:15 GMT
Message-ID: <3b3a6064.437118843@news.alt.net>

On Wed, 27 Jun 2001 23:14:16 +0100, "Jonathan Lewis" <jonathan_at_jlcomp.demon.co.uk> wrote:

>
>Change your insert text to include a bind variable,
>viz:
> 'insert into table select :b1, col1, ....'
>
>then your pl/sql wrapper does:
>
>m_var := seq.nextval
>m_string := {the string you have selected}
>
>execute immediate m_string using m_var;
>
>

And whgen I read "They can also contain placeholders for bind arguments. A placeholder is an undeclared identifier, so its name, to which you must prefix a colon, does not matter." I completely missed it. Thanx.

Brian Received on Wed Jun 27 2001 - 17:39:15 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US