Skip to Main Content

SQL & PL/SQL

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

EXECUTE IMMEDIATE for calling a function

624157Feb 10 2010 — edited Feb 11 2010
Can we use a execute immediate to call a function for which we get the parameters at the run time.

For example:-


query := ' select a,b, functionName(c) from table1, table2 where table1.a = table2.b'
execute immediate query bulk collect into myVar;


(here c is a column of table2)
now for each a from table1 there are 3 c from table 2.
the function basically calculates the sum of all c's.

Edited by: Pratiarun on Feb 10, 2010 8:09 PM
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Mar 11 2010
Added on Feb 10 2010
15 comments
2,564 views