Reputation: 21
I wanto update string to another string with method replace. I have been update success with MYSQL, but cassandra, I have a error. Thank for all!
This is commandline with MySQL:
update table_1
set field_1 = replace(field_1, 'hello', 'bonjour') where user_id = 9999;
Upvotes: 2
Views: 324
Reputation: 649
@LiamNguyen, you would achieve that in Cassandra as follows:
UPDATE table_1
SET field_1 = `bonjour`
WHERE user_id = 9999
IF field_1 = 'hello';
Additional References:
p/s: I am assuming user_id
is your primary key of that Cassandra table
Upvotes: 3