Returning multiple values from a PL/SQL FUNCTION.
Suppose I have a table XX_TEST which has two columns ID(number) and NAME(varchar2(20))
It has following values:-
ID NAME
1 RJ
1 NJ
2 AJ
2 PJ
Now I want to create a PL/SQL FUNCTION which has 1 parameter say P_ID.
where if I pass P_ID value as 1 then it should return values as RJ and NJ.
and if I pass P_ID value as 2 it should return AJ and PJ.
Kindly suggest.