Difficulty: Beginner
Estimated Time: 15 minutes

In this scenario, you will:

  • Create tables for an investment portfolio data use case
  • Populate tables with sample investment portfolio data
  • Design and execute CQL queries over investment portfolio data

This scenario is also available on our datastax.com/dev site, where you can find many more resources to help you succeed with Apache Cassandra™.

In this scenario, you explored:

  • Schema design for an investment portfolio use case
  • Sample investment portfolio data
  • CQL queries over investment portfolio data

Investment Portfolio Data Modeling Example for Cassandra

Step 1 of 10

Create a keyspace

Create the investment_data keyspace:

CREATE KEYSPACE investment_data
WITH replication = {
  'class': 'NetworkTopologyStrategy', 
  'DC-Houston': 1 };

Set the current working keyspace:

USE investment_data;