[
https://issues.apache.org/jira/browse/CASSANDRA-7771?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14706865#comment-14706865
]
Sylvain Lebresne commented on CASSANDRA-7771:
---------------------------------------------
bq. We should force someone to use an index name for any 2nd/3rd/4th index
added. I think we should do that even if the 1st created index did not use the
default name.
That comment makes me wonder if we're talking of the same thing. What I
understand in [~iamaleksey]'s suggestion is that we don't ever allow creating
the "same" index twice on the same column. So that we won't accept:
{noformat}
cqlsh:test> CREATE INDEX ON test(col);
cqlsh:test> CREATE INDEX ON test(col);
{noformat}
and we still wouldn't allow it if index names are provided. But we would allow
{noformat}
cqlsh:test> CREATE INDEX ON test(keys(col));
cqlsh:test> CREATE INDEX ON test(values(col));
{noformat}
for instance (assuming {{col}} is a {{map}}).
I'm fine with that but I don't think it's really related to forcing index names
or not (which I don't think we should).
> Allow multiple 2ndary index on the same column
> ----------------------------------------------
>
> Key: CASSANDRA-7771
> URL: https://issues.apache.org/jira/browse/CASSANDRA-7771
> Project: Cassandra
> Issue Type: New Feature
> Reporter: Sylvain Lebresne
> Assignee: Sam Tunnicliffe
> Labels: client-impacting
> Fix For: 3.0 beta 1
>
>
> Currently, the code assumes that we'll only have one 2ndary index per column.
> This has been reasonable so far but stop being it with CASSANDRA-6382 (you
> might want to index multiple fields of the same UDT column) and
> CASSANDRA-7458 (you may want to have one "normal" index an multiple
> functional index for the same column). So we should consider removing that
> assumption in the code, which is mainly 2 places:
> # in the schema: each ColumnDefinition only has infos for one index. This
> part should probably be tackled in CASSANDRA-6717 so I'm marking this issue
> as a follow-up of CASSANDRA-6717.
> # in the 2ndary index API: this is the part I'm suggesting we fix in this
> issue.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)