Http://www.2cto.com/database/201204/127180.html
Oracle implements the method by which the stored procedure returns a collection of query results-the method that implements the stored procedure to return a collection of query results, from the network grooming http://topic.csdn.net/u/20090721/12/ Ba403739-3212-4016-83ec-2a7062f21081.html
Java code--the first method of Create or replace package sysbasic as www.2cto.com type cc_cursor is REF CURSOR; End Sysbasic; CREATE OR REPLACE PROCEDURE getall (c_cursor out sysbasic.cc_cursor-cursor result) begin open C_cursor for Selec T * from table1; End GetAll; Www.2cto.com--The second method of Create or replace procedure P_test (P_cur out sys_refcursor) as begin open P_cur for Sele CT * from EMP; End P_test; In the Sqlplus interface: sql> var r refcursor; Sql> exec p_test (: R); sql> print R; Call using PL/SQL See the following link: http://blog.csdn.net/kimizhou_blog/article/details/39340851
Oracle stored procedure returns result set