Using Spark Cassandra Connector, I have a case where i want to use UPDATE IF EXISTS and if does not exist in table then ignore.
In the Cassandra documentation we have this condition in Cassandra 2.0.7 and later, you can conditionally update columns using IF or IF EXISTS.
Add IF EXISTS to the command to ensure that the operation is not performed if the specified row does not exist:
UPDATE cycling.cyclist_id SET age = 28 WHERE lastname = 'WELTEN' and firstname = 'Bram' IF EXISTS;
However, it's unclear to me if this can be done in the Spark Cassandra Connector. Does anyone know how this can be done?
答案 0 :(得分:1)
看起来这不是现在可以做的事情,但这是一个悬而未决的问题。
https://datastax-oss.atlassian.net/browse/SPARKC-386 - 由Andrew Mills回答