1
我试图将数据存储到cassandra中,并且按时间排序。使用TimeUUIDType作为关键时遇到问题。PHPCassa - 使用uuid时间戳作为密钥时无法插入
我碰到下面的错误与phpcassa ...
Fatal error: Uncaught exception 'cassandra_InvalidRequestException'
with message 'TimeUUID should be 16 or 0 bytes (6)'
调用insert方法时,就会出现此...
$pool = new ConnectionPool("Keyspace1", array("localhost:9160"));
$column_family = new ColumnFamily($pool, 'users');
$column_family->insert(CassandraUtil::uuid1(), array('name' => 'value'));
我创建使用卡桑德拉-CLI具有以下测试表命令
CREATE COLUMN FAMILY users WITH comparator = TimeUUIDType;