Friend List Table

Problem

What’s the schema for the friendlist table?

Solution

The friendlist table stores the friend lists created by users to organize their friends. Its fields are listed in Table 8-9. Queries to this table will only return data the current user is allowed to see (i.e., you can’t request friendlists for users other than the current loggedinuser). More information about this table, including an up-to-date listing of fields, can be found at http://wiki.developers.facebook.com/index.php/Friendlist_(FQL).

Table 8-9. friendlist table fields

Name

Type

Index

Description

flid

int

 

flid (friendlist ID) of this friend list.

name

string

 

Name of this friend list.

owner

int

uid (user ID) of the owner of this friend list. You can query only on the current loggedinuser.

Note that only the field marked as “Index” in this table can be used in an FQL query’s WHERE clause, but any of the fields can appear in the SELECT.

Discussion

If you’d rather use the API to access friendlists, try the Friends.getLists() method.

Get Facebook Cookbook now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.