Hello,
Is there any way to convert some HQL into a Criteria object? The Criteria objects seem to be more useful (in terms of tuning fetch strategies, etc.) yet I can't see an obvious mechanism I can write out my query in HQL but can't see how it's performed using a Criteria:
from Login l1, Login l2
where l1.time>=1197800000000 and l2.time>=1197800000000
and l1.time<1197904133904 and l2.time<1197904133904
and l1.id!=l2.id
and l1.user=l2.user
and abs(l1.time-l2.time)<1000)
Could someone show me how to create a Criteria that performs the above join?
Thanks,
John
|