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

altering a table to add a static column bypasses clustering column requirement check

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Normal
    • Resolution: Fixed
    • 2.0.10
    • None
    • Normal

    Description

      cqlsh:test_ks> create TABLE foo ( bar int, primary key (bar));
      cqlsh:test_ks> alter table foo add bar2 text static;
      cqlsh:test_ks> describe table foo;

      CREATE TABLE foo (
      bar int,
      bar2 text static,
      PRIMARY KEY ((bar))
      )

      cqlsh:test_ks> select * from foo;
      TSocket read 0 bytes

      ERROR [Thrift:12] 2014-08-09 15:08:22,518 CassandraDaemon.java (line 199) Exception in thread Thread[Thrift:12,5,main]
      java.lang.AssertionError
      at org.apache.cassandra.config.CFMetaData.getStaticColumnNameBuilder(CFMetaData.java:2142)
      at org.apache.cassandra.cql3.statements.SelectStatement.makeFilter(SelectStatement.java:454)
      at org.apache.cassandra.cql3.statements.SelectStatement.getRangeCommand(SelectStatement.java:360)
      at org.apache.cassandra.cql3.statements.SelectStatement.execute(SelectStatement.java:206)
      at org.apache.cassandra.cql3.statements.SelectStatement.execute(SelectStatement.java:61)
      at org.apache.cassandra.cql3.QueryProcessor.processStatement(QueryProcessor.java:158)

      Attachments

        1. 7730.txt
          2 kB
          Sylvain Lebresne

        Activity

          People

            slebresne Sylvain Lebresne
            tupshin Tupshin Harper
            Sylvain Lebresne
            Aleksey Yeschenko
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: