First question:- [Just as Concern]
How are you making sure that your PK is giving Uniqueness?
For Example:- At the same time, 10 users will write data then how's your
schema going to tackle that.
--------
Now on your question:-
does the read on the specific node happen first bringing all the metrics m1
- m100 and then the metric is  sliced in memory and retrieve ,  or the disk
read happens only on the sliced data m1 without bringing m1- m100  ?
In case of Selection, READ process will took place like below:-
First Cassandra will look into for ID = 10 then it will look in your
clustering range based on your timestamp given.



On Mon, May 21, 2018 at 4:34 PM, sujeet jog <sujeet....@gmail.com> wrote:

> Folks,
>
> consider a table with 100 metrics with (id , timestamp ) as key,
> if one wants to do a selective metric read
>
> select m1 from table where id = 10 and timestamp >= '2017-01-02
> :00:00:00'
> and timestamp <= '2017-01-02 04:00:00'
>
> does the read on the specific node happen first bringing all the metrics
> m1 - m100 and then the metric is  sliced in memory and retrieve ,  or the
> disk read happens only on the sliced data m1 without bringing m1- m100  ?
>
> here partition & clustering key is provided in the query, the question is
> more towards efficiency operation on this schema for read.
>
> create table {
> id : Int,.
> timestamp : timestamp ,
> m1 : Int,
> m2  : Int,
> m3  Int,
> m4  Int,
> ..
> ..
> m100 : Int
>
> Primary Key ( id, timestamp )
> }
>
> Thanks
>

Reply via email to