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 -> Clearification

Clearification

From: Pinne <pinne_at_pegit.se>
Date: Mon, 25 Oct 1999 15:52:56 +0200
Message-ID: <381460B8.8307B80C@pegit.se>


Pinne wrote:

> Are these types of statement possible from within an SP:
> SELECT col1, col2 FROM Table1;
> ?
> Ie. would it produce the same result as executing it from within SqlPlus
>
> SqlPlus gives me an error when i try to compile.
> Unless, i've cludged up the syntax. I doesn't seem possible.
>
> Is there another way to return result-sets from SP:s
>
> /Regards

Thanks for all the answers.
I guess i wasn't clear enough in my original posting (I'm a newbie on Oracle).

I'm using Oraperl.pm, a DBI-module for Perl 5.X. There You can execute a query via a function, "ora_open("SELECT col1, col2, From Table",...)"
Then retrieve all subsequent rows by repeatedly calling another function loop
{
($var1, $var2) = ora_fetch
}
I simply want to replace the SELECT-statement in the ora_open function with a call to an SP in this manner.

ora_open("EXEC sel_from_some_table($wherevar1, $wherevar2,..)",..)

(It ought to speed up things a lil, correct ? + all the other advantages SP:s has)

/Cheers
--
Björn-Åke Segrell / Pegit AB
Email:pinne_at_pegit.se
Url:http://www.pegit.se
Phone:+46-(0)8-56030220, Fax:+46-(0)8-56034353 Received on Mon Oct 25 1999 - 08:52:56 CDT

Original text of this message

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