Retrieves the likes for a target. Alternatively, lists pages that the specified user or page likes. Authentication is required to use this table.
Table Specific Information
Likes in Facebook represent the users that like a particular Target. The Target may be a Post, Page, Picture, or other type of valid entity that may have likes associated with it.
When selecting Likes, a Target must be specified. The target represents the user name or id of the entity likes are being retrieved for. For example:
SELECT * FROM Likes WHERE Target = '15526475270_410830705612736'
If a user or page is specified as the Target for Likes, then the pages that the user or page likes will be returned. For example:
SELECT * FROM Likes WHERE Target = 'facebook'
If no Target is specified, the currently authenticated user will be used as the Target. In this case, the pages that the authenticated user likes will be returned.
To insert an Like or to Like something, simply issue an INSERT statement and specify Target you are liking. The target must be an album, checkin, comment, photo, post, status update, or other object that can be liked. For example:
INSERT INTO Likes (Target) VALUES ('123456789_123456789')
Facebook does not allow likes to be updated.
Likes may be deleted by issuing a DELETE statement and specifying the Target you want to unlike. The Target represents the photo, post, comment, or other object you previously liked. The Id represents your user id. For example:
DELETE FROM LIKES WHERE Target='PostId' AND Id='MyUserId'
The id of user who likes the target which may or may not be combined with the target id. The user id will be after the final '_'.
The id or username of the target being liked. This may be a post, page, picture, or other valid id with likes.
The name of the user who likes the target. May alternatively be the name of a page.
The category of the user or page.
The time the like was created, if available.
Pseudo-Column fields are used in the WHERE clause of SELECT statements and offer a more granular control over the tuples that are returned from the data source. For more information, see the Where section.
Which result to begin returning results from. Used for manual paging of results.
This is used to page through multiple pages of results and should not be set manually.