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

Home -> Community -> Usenet -> c.d.o.server -> Re: help needed on executin a stored proc

Re: help needed on executin a stored proc

From: Michael Bialik <michael_bialik_at_my-deja.com>
Date: 2000/06/26
Message-ID: <8j8gvv$vdv$1@nnrp1.deja.com>#1/1

Hi.

 You have IN/OUT parm in your proc ( and it's cursor ).  To call it from SQLPlus you have to "wrap" it inside PL/SQL block.

 HTH. Michael

In article <8j8b6j$qkn$1_at_nnrp1.deja.com>,   rangneka_at_my-deja.com wrote:
> I have created the following package and proc:
>
> CREATE OR REPLACE PACKAGE PROCCURSORTYPES AS
> TYPE CHAR100_CUR IS REF CURSOR RETURN CHAR100TABLE%ROWTYPE;
>
> END PROCCURSORTYPES;
> /
>
> CREATE OR REPLACE PROCEDURE CHAR100PROC (
> CHAR100_CV IN OUT PROCCURSORTYPES.CHAR100_CUR,
> CHAR100_PARAM IN CHAR100TABLE.CHAR100FIELD%TYPE)
> AS
> BEGIN
> OPEN CHAR100_CV FOR SELECT * FROM CHAR100TABLE WHERE
> CHAR100FIELD=CHAR100_PARAM;
> END CHAR100PROC;
> /
>
> My applications can call and run this procedure no prblem with the
> corect data returned.
>
> My question is this: How would I call this procedure in SQL Plus?
>
> In SQL Plus I've tried:
>
> execute procedure name (cursor,param)
>
> but to no avail.
>
> Any ideas?
> Should the cursor parameter be set to 0?
>
> Any help would be appreciated.
>
> Shantanu
>
> Sent via Deja.com http://www.deja.com/
> Before you buy.
>

Sent via Deja.com http://www.deja.com/
Before you buy. Received on Mon Jun 26 2000 - 00:00:00 CDT

Original text of this message

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