cassandra-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Vivek Mishra <mishra.v...@gmail.com>
Subject Using Composite columns
Date Tue, 09 Oct 2012 01:59:02 GMT
Hi,
I am trying to use compound primary key with cassandra and i am referring
to:
http://www.datastax.com/dev/blog/whats-new-in-cql-3-0

I have created a column family as:

CREATE TABLE altercations (
       instigator text,
       started_at timestamp,
       ships_destroyed int,
       energy_used float,
       alliance_involvement boolean,
       PRIMARY KEY (instigator, started_at)
   );


then tried:

cqlsh:testcomp> select * from altercations;

(gives me no results, Which looks fine).

Then i tried insert statement as:

 INSERT INTO altercations (instigator, started_at, ships_destroyed,
                             energy_used, alliance_involvement)
                     VALUES ('Jayne Cobb', '7943-07-23', 2, 4.6, 'false');

(Sucess with this)

Then again i tried:

cqlsh:testcomp> select * from altercations;

it is giving me an error:

[timestamp out of range for platform time_t]


I am able to get that work by changing '7943-07-23' to '2012-07-23'.

Just wanted to know, why cassandra does not complain for {timestamp
out of range for platform time_t} at the time of persisting it?


-Vivek

Mime
View raw message