cayenne-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Aristedes Maniatis <>
Subject Re: EJBQL limit
Date Mon, 15 Aug 2016 06:43:21 GMT
On 15/08/2016 4:38pm, Andrus Adamchik wrote:
>> On Aug 14, 2016, at 4:39 PM, Hugi Thordarson <> wrote:
>> Hi all!
>> Does Cayenne’s EJBQL support LIMIT expressions? I see I can set a fetch limit on
an EJBQLQuery, but it seems that this will just limit the size of the resultset generated
by the query, not the SQL generation (resulting in huge execution times for large queries).
>> Cheers,
>> - hugi
> Yeah, the way it is implemented is not particularly efficient. The limit functionality
is external to the syntax, and hence doesn't make it to the generated SQL. We can either patch
EJBQL, or wait for the bright future when EJBQL and ObjectSelect and made one :)
> Andrus

Out of interest Hugi, why are you using EJBQL? Is this legacy code moved to Cayenne and this
was the easiest way forward? Or are there features of Cayenne's incomplete EJBQL implementation
you like better than the other SQL Template or ObjectSelect api?


Aristedes Maniatis
GPG fingerprint CBFB 84B4 738D 4E87 5E5C  5EFA EF6A 7D2E 3E49 102A

View raw message