Question

I was wondering today why google decided to do this for the google plus platform. I know I can handle these id's using varchars in mysql, but it's a bit weird to me why google decided to go for such big integers. An example google plus id is like this: 117634089072667507999

It's a very big integer which is out of the range of unsigned bigint on Mysql. Even with a big integer on mysql, it would take thousands of years to reach the limit of the id though there were millions of users signing in for google plus every second. So my question is, why did google choose such big integers?

Was it helpful?

Solution

Probably to allow them to use non-sequential IDs so that you can't deduce anything by comparing user IDs.

You should store them as strings, since you aren't using them as numbers (just like zip codes or phone numbers).

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top