0

I am defining different plsql expressions in table level for different types of validations, each validation has different functions with different parameters to evaluate condition. I am able to run one function with fixed parameters in one block , however i want run the execute immediate for any no of parameters there for particular function to run and get the results.

Using below example code for fixed no of parameters

Declare
  v_test_proc varchar2(50) := 'test_proc';
  p_user      varchar2(50) := 'test_name';
  p_code      varchar2(50) := 'test_code';
  p_error     varchar2(100);
  v_sql       varchar2(2000);
begin
  v_sql := 'begin ' || v_test_proc || '( :1 ,:2, :3 ); end;';
  execute immediate v_sql
    using p_user, p_code, out p_error;
  dbms_output.put_line(p_error);
end;
Adeel Aslam
  • 1,285
  • 10
  • 36
  • 69
  • Does this answer your question? [Oracle EXECUTE IMMEDIATE with variable number of binds possible?](https://stackoverflow.com/questions/1007912/oracle-execute-immediate-with-variable-number-of-binds-possible) – markalex Apr 05 '23 at 10:22

0 Answers0