dbTalk Databases Forums  

Re: Creating and calling stored procedure

comp.databases.oracle.tools comp.databases.oracle.tools


Discuss Re: Creating and calling stored procedure in the comp.databases.oracle.tools forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Michel Cadot
 
Posts: n/a

Default Re: Creating and calling stored procedure - 04-25-2007 , 10:36 AM







"Odd Bjørn Andersen" <obande (AT) online (DOT) no> a écrit dans le message de news: 462f446f$0$90269$14726298 (AT) news (DOT) sunsite.dk...
Quote:
I am very new to Oracle and have a simple question, which I can't easy find
an answer to in the documentation.

I want to write a simple stored procedure in PL/SQL with one input
parameter, and which returns 1 result set.
That should be very simple, but I can't find any examples for this simple
task in the documentation. Maybe
I haven't looked in the right places :-) Is there anyone who could help me
with an example?

And I also want to call this procedure from SQL*Plus, like this: call (or
execute) schema.proc (param=1) and get something like this in return:

Id Name Address
1 AA Street 1, 12345 Town
2 BB Street 5, 12345 Town
.....

Is that possible? And what is the syntax? And what if there are out
parameters, how do I specify them in the call (execute)
statement?

Regards
Odd B Andersen


http://download-uk.oracle.com/docs/c...5.htm#i1211948

Regards
Michel Cadot




Reply With Quote
  #2  
Old   
DA Morgan
 
Posts: n/a

Default Re: Creating and calling stored procedure - 04-25-2007 , 03:51 PM






Odd Bjørn Andersen wrote:
Quote:
I am very new to Oracle and have a simple question, which I can't easy find
an answer to in the documentation.

I want to write a simple stored procedure in PL/SQL with one input
parameter, and which returns 1 result set.
That should be very simple, but I can't find any examples for this simple
task in the documentation. Maybe
I haven't looked in the right places :-) Is there anyone who could help me
with an example?

And I also want to call this procedure from SQL*Plus, like this: call (or
execute) schema.proc (param=1) and get something like this in return:

Id Name Address
1 AA Street 1, 12345 Town
2 BB Street 5, 12345 Town
.....

Is that possible? And what is the syntax? And what if there are out
parameters, how do I specify them in the call (execute)
statement?

Regards
Odd B Andersen
http://www.psoug.org
Click on Morgan's Library
Click on REF CURSOR
--
Daniel A. Morgan
University of Washington
damorgan@x.washington.edu
(replace x with u to respond)
Puget Sound Oracle Users Group
www.psoug.org


Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.