I have a custom finder method "SELECT OBJECT(o) FROM Store AS o WHERE o.Id=?1".
Server is executing n (number of records which match the sql criteria) +1 queries.
How can I avoid this, so that I can get every thing back in first query.
Is "read-ahead" only solution?
thanks in advance.