sort the list of objects with the help of attribute in domain model

0
Can we sort the list of object of a perticular entity in domain model without using microflow so that I can use this in “executeMicroflowInBatches” java action as a Xpath. I have one entity where I am creating new object with the help of that. The latest object is come at the bottom of the list, if I use “executeMicroflowInBatches” then It goes at last  so I want latest object which goes 1st in batch
asked
2 answers
0

Hi Shubham, 

Can you try applying indexes to any of the attributes which help your recent object to appear as the first object? I haven't tried this before. Then try to use javaaction

answered
0

Hi shubham,

 

If I understand you correctly, you want to process your latest created object at first in the batch. I think your fastest and easiest option is, to check the system Entity Member DateCreated and do a Descend sort on that attribute. this will get you the lastests first and works it way up all the way to the oldest.

 

Hope this will get you in the right direction.

 

Good luck with it,

Jan

answered