ios - PFQuery using includekey -


i have 2 tables in parse.

  • activity
  • venues

activity holds 2 keys: userid , venueid. want query , retreive venue details in activity table.

i'm trying using this:

    pfquery *query = [pfquery querywithclassname:quoactivityclassname];     [query wherekey:quoactivityfavoritesuserid equalto:[pfuser currentuser]];     [query includekey:quoactivityvenueid];      if (self.objects.count == 0) {         query.cachepolicy = kpfcachepolicycachethennetwork;     }      return query; 

this retrieves object how grab specific fields in venues table name, address, etc.

you can venue returned object pfquery as:

venue * venue = object[quoactivityvenueid]; 

you can do:

nsstring * venuename = object[quoactivityvenueid][some_name_id]; nsstring * venueaddress = object[quoactivityvenueid][some_address_id]; 

Comments

Popular posts from this blog

c++ - Delete matches in OpenCV (Keypoints and descriptors) -

java - Could not locate OpenAL library -

sorting - opencl Bitonic sort with 64 bits keys -