cassandra - 将相同的数据插入 cassandra 数据库

标签 cassandra cassandra-0.7 cassandra-cli

我有一个问题,如果我们尝试将相同的数据插入到 cassandra 数据库中会怎样。在这里,我的意思是 cassandra 数据库中已经存在一组 100 行,比如在测试列族中。同样,如果我们尝试将相同的 100 行插入 cassandra 数据库,即具有相同 rowkey 的行,它会再次插入吗? .

最佳答案

它不会被复制,除非您将数据放在 中,否则它将被覆盖。不同 列族或键空间,然后您可以复制它。

Docs:
The first column value in the VALUES list is the row key value to insert. List column values in the same order as the column names are listed in the INSERT list. If a row or column does not exist, it will be inserted. If it does exist, it will be updated.

关于cassandra - 将相同的数据插入 cassandra 数据库,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/18203384/

相关文章:

java - 在 cassandra-cli 中如何获取表中的所有列名以及如何在 java 中使用 hector 获取它?

cassandra - 理解 Cassandra 背后的哲学

database - 选择带有允许过滤的低基数列会抛出错误 : No secondary indexes on the restricted columns support the provided operators

cassandra - cassandra 如何从 sstables 读取计数器列?

Cassandra 启动问题

java - 如何获取列值的类型

cassandra - 如何将cassandra与zookeeper集成以支持事务

Python cassandra 驱动程序-SSL : WRONG_VERSION_NUMBER

java - 如何让 Cassandra、Spring Boot 调用实体的字段 setter ?

cassandra - 在 Cassandra 中,为什么不允许从使用紧凑存储定义的表中删除列?