I have already found a workaround
SELECT DISTINCT booking FROM BookingEntity booking JOIN
booking.passengerSegments ps WHERE ps.openSegmentReservationDeadline IS NOT
NULL AND ps.openSegmentReservationDeadline < "2008-11-19 17:05:12" AND
ps.passengerSegments.objectStatus = "ACT" AND ps.reservationStatus = "OP"
It is strange why Toplink doesn't recognize that
booking.passengerSegments.objectStatus = "ACT" AND
booking.passengerSegments.reservationStatus = "OP" refer to the same table
--
View this message in context: http://www.nabble.com/redundant-joins-in-Toplink-Essentials-tp20583266p20600256.html
Sent from the java.net - glassfish persistence mailing list archive at Nabble.com.