0 votes

Cassandra no longer recognizes Keyspace creative command

I try to create a keyspace on Cassandra with the help of the tutorial of tuttorialspoint but there is a problem :When I do the command to create a Keyspace:

;CREATE KEYSPACE k1 WITH
    strategy_class = 'SimpleStrategy'
    AND trategy_otpions:replication_factor = '1';
    ...

O

cqlsh> CREATE KEYSPACE k1 WITH
   ... replication = {'class': 'strategy_class = 'SimpleStrategy'
   ... AND trategy_otpions:replication_factor = '1';
   ... 

When I touch the input it gives nothing, only '...'.

0voto

yeiniel Points 193

The problem is that there is a syntax error. You can see that you have a quotation mark before strategy_class that has no counterpart.

The correct sentence would be:

CREATE KEYSPACE k1
  WITH REPLICATION = { 
   'class' : 'SimpleStrategy', 
   'replication_factor' : 1 
  };

For more specific examples, please refer to the official documentation. here .

HolaDevs.com

HolaDevs is an online community of programmers and software lovers.
You can check other people responses or create a new question if you don't find a solution

Powered by:

X