Re: Oracle Queries/Paging
From: Dmitry E. Loginov <lde_at_mpsb.moris.ru>
Date: Fri, 15 Oct 1999 13:31:39 +0300
Message-ID: <3807028B.6DD45BAB_at_mpsb.moris.ru>
Date: Fri, 15 Oct 1999 13:31:39 +0300
Message-ID: <3807028B.6DD45BAB_at_mpsb.moris.ru>
Sorry, i overtyped...
[Quoted] U need to use group by in place showed below:
> U can build index for columns that u wanna to sort. And use hints..
> Or use next nested select:
>
> For ex we need to sort by Col_1, Col_2
> build index:
> create index YOUR_INDEX on YOUR_TABLE (Col_1, Col_2)
>
> use in select group by clause that implicitly use YOUR_IDEX and
> sort data
>
> select rn, col_1, col_2, Col_3, Col_4
> (select rownum rn, col_1, col_2, min(Col_3), Min(Col4)
> from YOUR_TABLE
group by rownum, col_1, col_2)
> where rn between :START_ROW and :END_ROW
Received on Fri Oct 15 1999 - 12:31:39 CEST