I need to store some timeseries data into redis. I have unix timestamps and that that i need to associate a value (timestamp <-> value)
I tried sorted sets having the timestamp as score (so i can do zrange on the timestamps) and the value as member.
127.0.0.1:6379> ZADD timeserie 1392141527245 10 1392141527275 12 1392141527100 10
(integer) 2
127.0.0.1:6379> zscan timeserie 0
1) "0"
2) 1) "10"
2) "1392141527245"
3) "12"
4) "1392141527275"
127.0.0.1:6379>
But i hit a problem, members are nonrepeating while my values can be the same for different timestamps. Any idea how to approach this? Is another data type better?
--
You received this message because you are subscribed to the Google Groups "Redis DB" group.
To unsubscribe from this group and stop receiving emails from it, send an email to redis-db+u...@googlegroups.com.
To post to this group, send email to redi...@googlegroups.com.
Visit this group at http://groups.google.com/group/redis-db.
For more options, visit https://groups.google.com/groups/opt_out.
--
--
You received this message because you are subscribed to a topic in the Google Groups "Redis DB" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/redis-db/3BurJghRCk4/unsubscribe.
To unsubscribe from this group and all its topics, send an email to redis-db+u...@googlegroups.com.
The shared counter idea is nice. In the past, for time series data in a zset, I have just prepended the timestamp to the values to make the set members, as well as using the timestamp for the score.
Keith Frost