Hi,

I'm attempting to build an index on a column acting as part of a composite key.

This is what I have so far:

CREATE TABLE userinfo2 (
       campaignId int,
       TS timestamp,
       somevalue text,
       PRIMARY KEY (campaignId, TS)
   );


INSERT INTO userinfo2 (campaignId, TS, somevalue) VALUES (23, '2012-10-01', 'Fuck that');
INSERT INTO userinfo2 (campaignId, TS, somevalue) VALUES (52, '2012-10-01', 'Fuck that too');


cqlsh:test1> CREATE INDEX campaignIdIndex ON userinfo2 (campaignId);
Bad Request: Cannot create index on PRIMARY KEY part campaignid
Perhaps you meant to use CQL 2? Try using the -2 option when starting cqlsh.


Building an index on other columns works, 
cqlsh:test1> CREATE INDEX campaignIdIndex ON userinfo2 (somevalue);



Am I doing something wrong? Are indexes on composite column supported ? If not, a suggestion for a work around?


Thank you,
Maxim.