我正在使用PFQueryTableViewController,我正在查询名为Group的PFObjects。这些组对象都与User PFObject有关系。我想通过仅查询具有包含当前用户的关系的组来为此查询添加约束。如何通过仅返回包含关系中当前用户的对象来向查询添加约束?
-(PFQuery *)queryForTable{
PFQuery * query = [PFQuery queryWithClassName:@"Group"];
//Users is a relation
[query whereKey:@"Users" equalTo:[PFUser currentUser]];
//This crashes the app
//I need to return only objects with current user in the users relation
return query;
}
由于