Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.misc -> Stored proc to return multiple rows

Stored proc to return multiple rows

From: T.A.V. <tav_at_sj.bigger.net>
Date: Sat, 30 May 1998 07:34:12 -0700
Message-ID: <357018E4.30B0A0B2@sj.bigger.net>

  1. Can somebody give me some hint how to create a stored procedure to return multiple rows from a table. For example, i would like my stored procedure returns a result set such as : select * from XXXX

I 'm using JDBC - Oracle thin driver. I would imagine that I would use ResultSet.next() to get the result for each row. Is it possible to do that?

2) Can I combine more than 2 statements in a stored procedure such as I would like to be able to do:

    select X, Y, Z, COUNT (*) from TABLE_1     select A, B, C , COUNT(*) FROM table_2 Can I have only procedure to perform both statements as above?

Many thanks in advance. Received on Sat May 30 1998 - 09:34:12 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US