Say I have an parent entity, each of which have a number of children. I want to get all the parents sorted by their number of children. Something similar to the following pseudo code:
NSEntityDescription * entity = [NSEntityDescription entityForName:@"Parent" inManagedObjectContext:managedObjectContext];
[[NSSortDescriptor alloc] initWithKey:@"children.count" ascending:NO];
//Execute request
Is there a way construct a fetch like this using core data? If there is no way to do this will sorting using sortedArrayUsingSelector:
loose the benefits of _PFBatchFaultingArray batch size?
Thanks, Ben