New Features of Oracle 12c: Paging Query

Source: Internet
Author: User
Tags oracle 12c documentation


The new feature of Oracle 12c paging query is expected in the upcoming oracle 12c release. This is the optimization of paging query. There are many paging query functions in the application. Previously we used rownum for this purpose.
For example, to query 1-10 records, the query statement is as follows: www.2cto.com SQL code select * from (select row _. *, rownum _ from (select doc_id, title, title_color, title_striking, upload_date, editor from ttt_doc) order by upload_date desc) row _ where rownum <= 10) where rownum _> 0; www.2cto.com is in 12c. You can do this. SQL code select doc_id, title, title_color, title_striking, upload_date, editor from ttt_doc order by upload_date desc fetch first 10 rows only; if you want to query 11 to 20 records, then you can do this. Www.2cto.com SQL code select doc_id, title, title_color, title_striking, upload_date, editor from ttt_doc order by upload_date desc offset 10 rows fetch next 10 rows only; this is more convenient than the previous operations. Of course, the more important thing is that the performance will be greatly improved. For more information, see the oracle 12c documentation.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.