function which will return multiple columns and rows values. [message #388852 is a reply to message #388849] |
Thu, 26 February 2009 06:36 |
nmascrene
Messages: 5 Registered: February 2009 Location: Mumbai
|
Junior Member |
|
|
I want to create function which will execute dynamic sql select query and return multiple rows and columns.
I went through the following post and made a function :
DBMS_SQL: DEFINE_ARRAY and COLUMN_VALUE problem in FORMS 6i [message #148505]
(This example is for multiple rows but one column)
but it is showing an error while compiling the package function
PLS-00306: wrong number or types of arguments in call to 'COLUMN_VALUE_CHAR'
I researched on this and im not able to find a good solution.
Example
---------
Supposing I have a table named emp with columns emp_names,emp_desigantion ,emp_id
and my query is
select emp_name,emp_designation from emp where emp_id >1 ;
how to I make use of DBMS_SQL.DEFINE_ARRAY in the function and return array with multiple columns and rows to the calling environment ie (forms 10g)
pls guide me on this using the above example.
|
|
|
|
|