【问题标题】:Update a user-defined type column in cql 5.1更新 cql 5.1 中的用户定义类型列
【发布时间】:2017-09-27 14:37:36
【问题描述】:

我想更新表中包含用户定义类型列的行。 所以,我对此进行了查询:

update test set identifiers = identifiers + {id : 'test1', cat_name : 'test1'} where id = 1;

这是我的表格测试:

CREATE TABLE public.test ( id int PRIMARY KEY, identifiers frozen<identifier> )

提前谢谢你

【问题讨论】:

    标签: cassandra cql


    【解决方案1】:

    将 Squire 括号放在花括号之前。它将向现有行添加新行。 如下图。

    更新测试集标识符 = 标识符 +[{id :'test1',cat_name:'test1'}] where id = 1

    【讨论】:

      猜你喜欢
      • 2018-05-08
      • 2016-01-19
      • 2016-05-05
      • 2021-01-21
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2013-05-22
      相关资源
      最近更新 更多