Using bind variables with dynamic SELECT INTO clause in PL/SQL

前端 未结 5 1373
深忆病人
深忆病人 2020-12-01 02:30

I have a question regarding where bind variables can be used in a dynamic SQL statement in PL/SQL.

For example, I know that this is valid:

CREATE OR          


        
5条回答
  •  眼角桃花
    2020-12-01 03:37

    Select Into functionality only works for PL/SQL Block, when you use Execute immediate , oracle interprets v_query_str as a SQL Query string so you can not use into .will get keyword missing Exception. in example 2 ,we are using begin end; so it became pl/sql block and its legal.

提交回复
热议问题