union
英 [ˈju:niən] 美 [ˈjunjən]
n.同盟,联盟;协会,工会;联合,团结
adj.工会的
复数: unions
store
英 [stɔ:(r)] 美 [stɔr, stor]
n.商店;贮存物;仓库;大量
v.贮存;(在计算机里)存储
第三人称单数: stores 复数: stores 现在分词: storing 过去式: stored 过去分词: stored
redis SUNIONSTORE命令 语法
作用:这个命令类似于 SUNION 命令,但它将结果保存到 destination 集合,而不是简单地返回结果集。如果 destination 已经存在,则将其覆盖。destination 可以是 key 本身。
语法:SUNIONSTORE destination key [key ...]
可用版本:>= 1.0.0
时间复杂度:O(N), N 是所有给定集合的成员数量之和。
返回:结果集中的元素数量。
redis SUNIONSTORE命令 示例
redis> SMEMBERS NoSQL 1) "MongoDB" 2) "Redis" redis> SMEMBERS SQL 1) "sqlite" 2) "MySQL" redis> SUNIONSTORE db NoSQL SQL (integer) 4 redis> SMEMBERS db 1) "MySQL" 2) "sqlite" 3) "MongoDB" 4) "Redis"