tags:

views:

107

answers:

0

I have Entity A. Entity B is child table for A and is abstract with DISCRIMINATOR.

Entity C and D extends B with discrimatot values 'A' and 'R' respectively

How do I select A which has B with status 'A'.

Is some thing like this possible.. select a from A as a join fetch a.b as b where b IS C ??

Or Do I need to fetch b and check as follows
if(a.getB instanceof C){

}