I want to create a PFQuery for a PFRelation to find objects where the specified relation has zero objects in it. Here's what I've tried:
PFQuery *categoryQuery = [CatalogCategory query];
[categoryQuery whereKeyDoesNotExist:@"subcategories"];
But I get an error saying I can't use this operator on a PFRelation key. How else could I achieve what I'm looking for?
Have you tried [categoryQuery whereKey:@"subcategories" equalTo:nil]
?
It may be that the whereKeyDoesNotExist:
method is unavailable for objects of the PFRelation
type.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.