Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » EclipseLink » Pagination - FIRST_ROWS_N
Pagination - FIRST_ROWS_N [message #984557] Wed, 14 November 2012 15:09 Go to previous message
Mauro Flores is currently offline Mauro Flores
Messages: 83
Registered: September 2009
Location: Brasil
Member
How to create a JPA query with pagination parameters (setFirstRows and setMaxRows) and obtain a SQL query like this to run on oracle data base:


SELECT * FROM (SELECT /*+ FIRST_ROWS_10 / a., ROWNUM rnum FROM (...)

Today the SQL query is generated like:

SELECT * FROM (SELECT /*+ FIRST_ROWS / a., ROWNUM rnum FROM (...)

The second way is far slower than the first.

Is there a query hint to make this customization? I'm using eclipselink 2.1.3.

Thanks. Mauro Flores.


[Updated on: Wed, 14 November 2012 15:10]

Report message to a moderator

 
Read Message
Read Message
Previous Topic:How to ise dynamic fetchgroup
Next Topic:Postgres inet type
Goto Forum:
  


Current Time: Wed May 22 14:56:37 EDT 2013

Powered by FUDForum. Page generated in 0.01569 seconds