April 2017
Beginner to intermediate
360 pages
9h 35m
English
Another surprising fact about counter columns is that they cannot coexist with regular data columns in the same table. For instance, let's imagine that along with view counts, we'd like to record the timestamp of the last view of a status update on a given day. We might think we can add a timestamp column to our daily_status_update_views table:
ALTER TABLE "daily_status_update_views" ADD "last_view_time" timestamp;
However, if we attempt to perform this schema modification, we'll see an error:

Cassandra requires that counter columns live in their own table; they cannot coexist with regular data columns ...
Read now
Unlock full access