title: Display list of friends using same in uitableview
body: <p>i'm struggling to get this done. I 've made a FBRequest to see who (in my facebook friends) have installed my app.</p>
  
  <p>Here is my code</p>
  
  <pre><code>-(void)viewDidload
  {
  
  
      [[FBRequest requestForMe] startWithCompletionHandler:
       ^(FBRequestConnection *connection, NSDictionary&lt;FBGraphUser&gt; *user, NSError *error) {
           if (!error) {}
  
           NSString* fql =
           @"SELECT uid FROM user WHERE is_app_user=true AND uid IN (SELECT uid2 FROM friend WHERE uid1 = me())";
  
           [FBRequestConnection startWithGraphPath:@"/fql"
                                        parameters:@{ @"q" : fql}
                                        HTTPMethod:@"GET"
                                 completionHandler:^(FBRequestConnection *connection, id result, NSError *error) {
                                     if(error) {
                                         // NSLog(@"Problem");
                                     }
                                     FBRequest *fql = [FBRequest requestForGraphPath:@"fql"];
                                     [fql.parameters setObject:@"SELECT uid,name,is_app_user FROM user WHERE is_app_user AND uid IN (SELECT uid2 FROM friend WHERE uid1 = me())" forKey:@"q"];
  
                                     [fql startWithCompletionHandler:^(FBRequestConnection *connection,
                                                                       id result,
                                                                       NSError *error) {
                                         if (result) {
                                             //NSLog(@"result:%@", result);
  
                                             //ON PARSE LE RESULT
  
                                             NSArray *arrayRsult = [result objectForKey:@"data"];
                                             NSMutableArray *ins = (NSMutableArray *) [arrayRsult valueForKey:@"is_app_user"];
                                             NSMutableArray *ids = (NSMutableArray *) [arrayRsult valueForKey:@"uid"];
                                             NSMutableArray *names = (NSMutableArray *) [arrayRsult valueForKey:@"name"];
  
                                             NSMutableArray *recentFriends = [[NSMutableArray alloc] init];
                                             NSMutableArray *idFriends = [[NSMutableArray alloc] init];
                                             NSMutableArray *nameFriends = [[NSMutableArray alloc] init];
  
  
                                             // ON A LE NOMBRE D'USER
  
                                             for (NSDictionary *d in ins)
                                             {
                                                 [recentFriends addObject:d];
                                                 [recentFriends removeObjectIdenticalTo:[NSNull null]];
  
  
  
                                             }
  
                                             // ON A LES IDS
  
  
                                             for (NSDictionary *e in ids)
                                             {
                                                 [idFriends addObject:e];
  
  
  
                                             }
                                             // ON A LES NOMS
  
                                             for (NSDictionary *e in names)
                                             {
                                                 [nameFriends addObject:e];
  
  
  
                                             }
  
                                             NSUInteger arrayLength = [recentFriends count];
  
                                             NSLog(@"ids are : %@ ",idFriends);
                                             NSLog(@"names are %@",nameFriends );
  
                                             NSLog(@"there are %i", arrayLength);
  
  
                                             data = [NSArray arrayWithObjects:nameFriends, nil];
                                             displayData = [[NSMutableArray alloc]initWithArray:data];
  
                                         }
  
                                         else {
  
  
                                             NSLog(@"problem , bullshit");}
                                     }];
                                 }
            ];}];
  
      data = [NSArray arrayWithObjects:nameFriends, nil];
      displayData = [[NSMutableArray alloc]initWithArray:data];
  
  }
  
  
  - (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath
  {
  
  
  
      UITableViewCell *cell = [[UITableViewCell alloc]
                               initWithStyle:UITableViewCellStyleDefault
                               reuseIdentifier:@"cell"];
  
  
  
  
  
      cell.textLabel.text = [displayData  objectAtIndex:indexPath.row];
  
      return cell;
  }
  
    - (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section
      {
  
      return [displayData count];
  
     }
  </code></pre>
  
  <p>In the console I have the id , the number of persons who have the app and the name of them.
  And now, I want to display the result of the NameFriends MutableArray in a tableView.</p>
  
  <p>The data I want to show doesnt appear when I write the NSLogs outside the facebook requests.. they seem to be null.</p>
  
  <p>It's the last step to end this part of the project and sadly i can't do this by myself</p>