I have a form with over 20 fields. The user can select any combination of these fields for the search. I am passing these field values to a procedure. Depending on which fields are 'NOT NULL', I am building the sql statement. This sql statement is then being passed as parameter to a procedure for executing the query. I am using the following code:
PROCEDURE TEST1 (
office IN CHAR DEFAULT NULL,
iid IN CHAR DEFAULT NULL,
.
.
.
stmt varchar2;
)
How can I use this with DBMS_SQL to retrieve values from the table and display them on the web? When I use:
dbms_sql.parse(cur, stmt, dbms_sql.native);
I get an error 'invalid colmn name'.