我有2个资源用户和相册.用户有一个专辑列表.要获得专辑,有2个REST API.
我是Cassandra的新手.我遇到了一个问题CQL IN query,如果表有SET类型列它可以工作.
CREATE TABLE test (
test_date bigint,
test_id bigint,
caption text,
PRIMARY KEY(test_date,test_id)
);
select * from test where test_date = 2022015 and test_id IN (1,2);
Run Code Online (Sandbox Code Playgroud)
但如果我添加上面设置的标签,那么它会给出错误
CREATE TABLE test1 (
test_date bigint,
test_id bigint,
tags set<text>,
caption text,
PRIMARY KEY(test_date,test_id)
);
select * from test1 where test_date = 2022015 and test_id IN (1,2);
Run Code Online (Sandbox Code Playgroud)
code = 2200 [无效查询] message ="无法通过IN关系限制列"test_id",因为查询选择了一个集合"
嗨,我有两个SomeType a1,a2的集合,并希望从a1中删除a2的所有元素.
请建议我需要使用哪种类型的Collection:
这有什么图书馆吗?