Vote count:
0
I'm trying to accomplish an orderBy by the concrete subclass of an entity. My query itself queries for the abstract baseclass and I want to order the result based on the concrete subclass. Unfortunately I don't find an appropriate field like e.g. 'entityClass' or something similiar in the generated Q-Classes.
So e.g. if I have the class hierary BaseClass with subclasses SubClassA and SubClassB I would like to get a resulting list which first contains all Entities of type SubClassA and after that the Entities of type SubclassB. In my inheritance strategy it would be the same as adding an orderby on the discriminator column.
Does anyone know if this is possible with queryDSL? Any help is greatly appreciated.
asked 1 min ago
queryDSL: order by entity (sub)class
Aucun commentaire:
Enregistrer un commentaire