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 -> Re: procedure returning 2 rows

Re: procedure returning 2 rows

From: Ana C. Dent <anacedent_at_hotmail.com>
Date: Sat, 27 Jan 2007 05:36:09 GMT
Message-ID: <Xns98C4DBC046A9Eanacedenthotmailcom@69.28.173.184>


"dazed_confused_lost" <dazed_confused_lost_at_hotmail.com> wrote in news:1169871858.388061.174200_at_l53g2000cwa.googlegroups.com:

> I am stuck. Yes I have read the documentation. I was not able to
> memorize it though. I have searched google, asktom, oracle.com and my
> bookshelf of books on Oreilly safari and many google group posts. I am
> still stuck.
>
> Could someone kindly post a Oracle 9i PL/SQL example that simply
> SELECTs 2 rows from a table and then displays those rows? Also please
> include the syntax needed to call the procedure and display those 2
> damn rows.
>
> I will run it in toad or sqlplus.
>
> A complete full example would include 2 more things.
> create table statement (separate from procedure)
> insert statement (inserting 2 rows) (also separate from procedure)
>
> I need a full working example, not a link to a another website.
>
>

With advice you can have it, good,fast, or cheap pick any 2.

SELECT * FROM ANY_TABLE WHERE ROWNUM <3;

The 2 rows are totally arbitrary; but you will get 2 rows. Received on Fri Jan 26 2007 - 23:36:09 CST

Original text of this message

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