I have a large SELECT statement that uses prompt (bind) variables. The statement is (> 4000 characters and I need to call it in a Procedure (or similar object) by passing in, say 3 variables.
What is the best way to go about this task? Assuming that my SELECT is something like this (but > 4000 characters):
SELECT many_cols, FROM many_tables WHERE col1 = &var1 and col2 = &var2 and col3 = &var3.
I'm looking for a high-levell approach, with the general code flow, that I can add the full SELECT statement and call from another application (just as BEPL) with a simple statement - while passing in these three variables.