我有一个 Cassandra 1.2 集群,我使用 cql 库从 Python 中使用它。现在我需要使用 get_slice 实现一些看起来非常简单的分页功能,但我找不到任何有关如何使用 cql 库中的类似功能的文档:
get_slice("key" : table_key,
"column_parent" : {"column_family" : "MyColumnFamily"},
"predicate" :
{ "slice_range" :
{ "start" : "SomeStartID",
"end" : "Z",
"reverse" : "false",
"count : "100" }
} )
Run Code Online (Sandbox Code Playgroud)
我在 get_slice 的随机文档中看到过这种类型的语法,它看起来不像 CQL 3 语法,我如何从 Python 到 Cassandra 1.2 集群运行这种类型的查询?,这是使用 get_slice 的当前方式或者有新的语法或 CQL 3 替代方案?
提前致谢!