mismatched input ')' expecting EOF in CQL

12,454

Cassandra 1.0 has CQL2, and your statement is only valid in CQL3. You should upgrade to 1.2.10 or 2.0.1 since 1.0 is very old and CQL2 is deprecated.

Share:
12,454
user2801682
Author by

user2801682

Updated on June 04, 2022

Comments

  • user2801682
    user2801682 almost 2 years

    created keyspace and using CQL but getting an Error

    CREATE KEYSPACE demodb
               WITH strategy_class = 'org.apache.cassandra.locator.SimpleStrategy'
      ...          AND strategy_options:replication_factor='1';
    
    cqlsh:demodb> CREATE TABLE users (
          ...                 user_name varchar,
          ...                 password varchar,
          ...                 gender varchar,
          ...                 session_token varchar,
          ...                 state varchar,
          ...                 birth_year bigint,
          ...                 PRIMARY KEY (user_name)
          ...               );
    Bad Request: line 1:163 mismatched input ')' expecting EOF
    

    why am i getting this error,any help,thanks.