ledome20 wrote:
I'm not quite sure, i can't see all your entities,
but you can try something like that:
select item from Item as item left join item.order as order where order.customer_id = :custId and isNull(order.item)
I did not understand what else entities I need to describe
imagine there are not more entities. ;-)
provided query won't work even if it have correct syntax ;-)
like this one
select item from Item as item left join item.orders as order where order.customer_id = :custId and order.item is null;
It doesn't work because it puts criteria to where clause instead of join clause.
PS I still wounder if it _posible_ to put criteria in hibernate join clause?