Updating multiple columns

As in the SQL UPDATE statement, we can specify multiple column-value pairs to be updated in a single statement. Let's say dave wants to change his e-mail address and also enter a location:

UPDATE "users" SET "email" = 'dave@me.com', "location" = 'San Francisco, CA' WHERE "username" = 'dave'; 

On checking the table again, we see that both columns have been updated in the dave row:

Get Learning Apache Cassandra - Second Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.