Uploaded image for project: 'Apache Cassandra'
  1. Apache Cassandra
  2. CASSANDRA-7804

Confusing error message when condition is set on primary key column

    XMLWordPrintableJSON

Details

    • Low

    Description

      If you set a CAS condition on a primary key column, you'll get an error that's somewhat confusing:

      cqlsh:ks1> CREATE TABLE mytable (a int PRIMARY KEY, b int);
      cqlsh:ks1> UPDATE mytable SET b = 0 WHERE a = 0 IF a = 0;
      code=2200 [Invalid query] message="PRIMARY KEY part a found in SET part"
      

      Attachments

        1. 7804-2.1.txt
          1.0 kB
          Tom Hobbs

        Activity

          People

            thobbs Tom Hobbs
            thobbs Tom Hobbs
            Tom Hobbs
            Sylvain Lebresne
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: