I cannot find any decent documentation on the Instagram API about this. I know it returns a number through the API which is usually a 2^32 bit int, but once in a while I will get a number that is 2^64. I want to store these numbers in my Cassandra database, but I am not sure if I should store them as Int(2^32) or BigInt(2^64) or even text.
What are your thoughts?
Based on the Instagram API, id's (whether for a User, Media, Location, etc) are returned as strings (as opposed to the float values for "latitude" and "longitude" or the int values returned for fields like count):
{
"data": [{
"id": "788029",
"latitude": 48.858844300000001,
"longitude": 2.2943506,
"name": "Eiffel Tower, Paris"
},
{
"id": "545331",
"latitude": 48.858334059662262,
"longitude": 2.2943401336669909,
"name": "Restaurant 58 Tour Eiffel"
},
{
"id": "421930",
"latitude": 48.858325999999998,
"longitude": 2.294505,
"name": "American Library in Paris"
}]
}
It may be best to store them as text in Cassandra.