可能重复:
how to have 64 bit integer on PHP?
在使用PHPCassa的Cassandra中,是否可以使用64位长整数作为键?
例如,
$pool = new ConnectionPool('main', array("127.0.0.1"));
$table = new ColumnFamily($pool, 'messages'); // ColumnFamily
$table->insert("5601379860409749867", array("sampleKey" => "sampleValue)); 每次我做插入时,我的密钥都是0。在这个表中,key_validation_class是LongType。
发布于 2012-07-30 16:53:27
这完全取决于服务器的操作系统功能,而不是PHPCassa的限制。
本机64位整数需要64位硬件和64位PHP版本.
在32位硬件上:
$ php -r 'echo PHP_INT_MAX;'
2147483647在64位硬件上:
$ php -r 'echo PHP_INT_MAX;'
9223372036854775807https://stackoverflow.com/questions/10341474
复制相似问题