How to return resultset from stored procedure In ORACLE
Hey some people thinking about its simple retreive data from query rather than stored procedure. But is more simple and safe to so do changes if required. For that we need to follow steps as follows : [Note : Creating stored proc. and package only through sqlplus] 1) We need to package of oracle to create it. Packages in oracle syntax : CREATE OR REPLACE PACKAGE SELECT_EMP_HISTORY AS TYPE T_CURSOR IS REF CURSOR; PROCEDURE Sp_Test_Emp_Data ( p_year IN VARCHAR2, cur_JobHistory OUT T_CURSOR ); END SELECT_EMP_HISTORY; / Create Package Body : CREATE OR REPLACE PACKAGE BODY SELECT_EMP_HISTORY AS PROCEDURE Sp_Test_Emp_Data ( ...