Re: Limit Rows in sql query output

From: vijay sehgal <vijaysehgal21_at_gmail.com>
Date: Wed, 18 Jun 2014 16:05:25 +0530
Message-ID: <CALQThVd+=29a+z=OkcsV8+t05cUDH+D3hK8Mt--7SMS2cw0Z2g_at_mail.gmail.com>



Bala,

Hope the below article by Thomas Kyte helps.

http://www.oracle.com/technetwork/issue-archive/2006/06-sep/o56asktom-086197.html

On Wed, Jun 18, 2014 at 3:01 PM, Bala Krishna <krishna000_at_gmail.com> wrote:

> Hi All,
>
> We are intrested in fetching output on rows wise for ex.
>
> in first iteration 1 .. 50
> second iteration 51 .. 100
> Third iteration 101 .. 150 so on .
>
> SELECT * FROM (SELECt m.*,rownum r FROm EM_INFO m ORDER BY DBNAME ASC)
> WHERE r >=1 AND r <=50
>
> or
>
> SELECT * FROM (SELECt m.*,rownum r FROm EM_INFO m ) WHERE r >=1 AND r <=50
> and ORDER BY DBNAME ASC
>
> I've tried with both the above queries but its not displaying in the
> sorted order Can somebody help me pls .
>
> Regards
> Bala
>
>

--
http://www.freelists.org/webpage/oracle-l
Received on Wed Jun 18 2014 - 12:35:25 CEST

Original text of this message