Question-17: Map the following

  1. Clustering column
  2. Materialized View
  3. Partition Key

 

 

  1. Using this data can be divided in logical groups.
  2. It helps in retrieving data sorted by date column.
  3. You can build another table using the existing table.

Ans: A-2, B-3, C-1

Exp: In Cassandra database you can store data in a table similar to RDBMS which must have a primary key.

With the help of partition key, it can be decided on which node data should be stored and you can divides data into logical groups. Using partition key data will be distributed evenly across the nodes in cluster. Please note:  for efficiency and performance query and write requests across multiple partitions should be avoided.

Clustering column: Using the clustering column data will be sorted within the partition. Suppose you want to fetch the data sorted by a date column then define date column as a cluster column.

Materialized view: Similar to RDBMS this are the tables created using the other tables. And you can have different primary key and even set different properties. If you change the data in underline table from this view is created then data in the materialized view can also updated