While working on legacy Facebook applications recently migrating them to the latest Graph API, I fixed the data types of Facebook ID columns in several apps. Some had used the varchar data type and others had simple ‘Text’ type.
Since Facebook assigns the IDs to users, and we are just storing them in our apps, I prefer using BIGINTs MySQL data type for storing them. The fbid column should be made UNSIGNED due to obvious reasons.
To make comparisons easier and creating indexes, BIGINTs are the way to go. I successfully removed some “Empty response received” error from one app by only adding indexes on some columns including the fb_id.