You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cassandra.apache.org by "Tyler Hobbs (JIRA)" <ji...@apache.org> on 2015/02/10 19:59:13 UTC

[jira] [Comment Edited] (CASSANDRA-8154) desc table output shows key-only index ambiguously

    [ https://issues.apache.org/jira/browse/CASSANDRA-8154?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14314663#comment-14314663 ] 

Tyler Hobbs edited comment on CASSANDRA-8154 at 2/10/15 6:58 PM:
-----------------------------------------------------------------

Thanks, the bundled python driver has been upgraded to commit {{077b876fdd38}} (2.1.4.post) as commit {{f5380de}}.


was (Author: thobbs):
Thanks, the bundled python driver has been upgraded {{077b876fdd38}} as commit {{f5380de}}.

> desc table output shows key-only index ambiguously
> --------------------------------------------------
>
>                 Key: CASSANDRA-8154
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-8154
>             Project: Cassandra
>          Issue Type: Bug
>            Reporter: Russ Hatch
>            Assignee: Tyler Hobbs
>            Priority: Minor
>              Labels: cqlsh
>             Fix For: 2.1.4
>
>
> When creating a secondary index on a map type, for keys, the DESC TABLE output does not create correct DDL (it omits the keys part). So if someone uses describe to recreate a schema they could end up with a values index instead of a keys index.
> First, create a table and add an index:
> {noformat}
> CREATE TABLE test.foo (
>     id1 text,
>     id2 text,
>     categories map<text, text>,
>     PRIMARY KEY (id1, id2));
> create index on foo(keys(categories));|
> {noformat}
> Now DESC TABLE and you'll see the incomplete index DDL:
> {noformat}
> CREATE TABLE test.foo (
>     id1 text,
>     id2 text,
>     categories map<text, text>,
>     PRIMARY KEY (id1, id2)
> ) WITH CLUSTERING ORDER BY (id2 ASC)
> .......................snip..............................................
> CREATE INDEX foo_categories_idx ON test.foo (categories);
> {noformat}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)