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

Throw errror when attempting to create a secondary index against counter

    XMLWordPrintableJSON

Details

    • Low

    Description

      Using CQL you can create a secondary index against a counter which is then non-functional.

      cqlsh:test> create table test2 (col1 int, col2 counter, primary key (col1)) ;
      cqlsh:test> create index dodgy on test2(col2) ;
      cqlsh:test> update test2 set col2 = col2 + 0 where col1 = 1 ;
      cqlsh:test> select * from test2 ;
      
       col1 | col2
      ------+------
          1 |    0
      
      cqlsh:t7088> select * from test2 where col2 = 0 ;
      

      We should return an error to let users know they are in unsupported territory.

      Attachments

        1. 6160.txt
          1 kB
          Sylvain Lebresne

        Activity

          People

            slebresne Sylvain Lebresne
            ahattrell Adam Hattrell
            Sylvain Lebresne
            Jonathan Ellis
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: