Hello,
I’m trying to get a view with startkey and endkey parameters but i’ve strange results.
My view :
function (doc, meta) {
emit([doc.id, doc.request_time], { “id” : doc.id, “group” : doc.group, “message”:doc.message, “level”: doc.level, “url”:doc.url, “sbt”:doc.sbt, “request_time”:doc.request_time, “site_id”:doc.site_id });
}
doc.id = 28
doc.request_time = 1272817191 (timestamp)
and the query :
_view/by_time?stale=false&startkey=[24%2C+1]&endkey=[31%2C+1272817191]&connection_timeout=60000&limit=10&skip=0
startkey=[24, 1]
endkey= [31, 1272817191]
In fact, i want docs which their id > x et request_time < x. I have trouble to do this, so i try to do id >24 and <31 and request_time >1 and < 1272817191. Look the result (i just put keys result) :
[25,1372837191] [26,1372817191] [27,1372817191] [28,1372817191] [29,1172817191] [30,1072817191]
I don’t understand why 25, 26, 27, 28 are return…
Thanks for helping