You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@cassandra.apache.org by Thomas Borg Salling <tb...@tbsalling.dk> on 2015/03/03 10:17:47 UTC
Does DateTieredCompactionStrategy work with a compound clustering key?
Does DateTieredCompactionStrategy in Apache Cassandra 2.1.2. work with a
compound clustering key?
More specifically would it work for a table like this where (timestamp,
hash) makes up a compound clustering key:
CREATE TABLE sensordata (
timeblock int,
timestamp timestamp,
hash int,
data blob,
PRIMARY KEY (timeblock, timestamp, hash)
)
I believe, that the DateTieredCompactionStrategy would work for PRIMARY KEY
(timeblock, timestamp) -- but does it also work for PRIMARY KEY (timeblock,
timestamp, hash) ?
Thanks in advance for any input,
/Thomas.
Re: Does DateTieredCompactionStrategy work with a compound clustering
key?
Posted by mck <mc...@apache.org>.
> I believe, that the DateTieredCompactionStrategy would work for PRIMARY
> KEY (timeblock, timestamp) -- but does it also work for PRIMARY KEY
> (timeblock, timestamp, hash) ?
Yes.
(sure you don't want to be using a timeuuid instead?)
~mck