[
Date Prev][
Date Next][
Thread Prev][
Thread Next][
Date Index][
Thread Index]
[
List Home]
Re: [eclipselink-users] Batch Reading Ignores paging using setFirstResults / setMaxRows
|
Answered my own question:
query.getBatchFetchPolicy().setType(BatchFetchType.IN);
I figured you guys had thought of this, super efficient now Thanks! :)
./tch
On Fri, Mar 11, 2011 at 10:10 AM, Tim Hollosy <hollosyt@xxxxxxxxx> wrote:
> Is there anyway to get eclipselink's batch read functionality to
> respect the setFirstResults setMaxRows set on a ReadAllQuery?
>
> I have what I'd believe would be a pretty common pattern -- paging
> through a large dataset, then pulling over a lazy collection for
> everything on the page, however when I use a batch query hint or
> manually add the batchReadAttribute to the query the select is going
> against the full expression without the rownum bit in there.
>
> Any ideas on how to be more effecient here? The only thing I can come
> up with is manually creating an in statement and populating the
> collections myself.
>
> Thanks!
>
> ./tch
>