Thierry Boileau created CASSANDRA-5069: ------------------------------------------
Summary: cassandra "show schema" command does not export correctly primary key created via cqlsh Key: CASSANDRA-5069 URL: https://issues.apache.org/jira/browse/CASSANDRA-5069 Project: Cassandra Issue Type: Bug Components: Tools Affects Versions: 1.1.6 Reporter: Thierry Boileau 1/ create a column family as follow in cqlsh CREATE TABLE "Test" ( "id" varchar, "email" varchar, PRIMARY KEY ("id") ); 2/ with cassandra-cli, use the "show schema" command: create column family Test with column_type = 'Standard' and comparator = 'UTF8Type' and default_validation_class = 'UTF8Type' and key_validation_class = 'UTF8Type' and read_repair_chance = 0.1 and dclocal_read_repair_chance = 0.0 and gc_grace = 864000 and min_compaction_threshold = 4 and max_compaction_threshold = 32 and replicate_on_write = true and compaction_strategy = 'org.apache.cassandra.db.compaction.SizeTieredCompactionStrategy' and caching = 'KEYS_ONLY' and column_metadata = [ {column_name : 'email', validation_class : UTF8Type, index_name : 'authorizedemail_email', index_type : 0}] and compression_options = {'sstable_compression' : 'org.apache.cassandra.io.compress.SnappyCompressor'}; NB : note there is no "id" column definition 3/ recreate the column family using the creation script generated by show schema 4/ select * from "Test"; key | email | --------------------------------------+-------------------------------+ The "id" column has been renammed to "key". -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira