On Aug 1, 2010, at 2:43 PM, Avi Flax wrote:
> Hi all, quick question — i'm having a little trouble with paging with
> startkey_docid
>
> I have a view whose keys look like: ["foo", "bar", "2010-06-10T12:14:35Z"]
>
> I'm querying the view with startkey=["foo", "bar"] and endkey=["foo","bar",{}]
>
> Which is returning what i expect, but i'm having trouble doing paging
> with this scenario; it almost seems like startkey_docid is being
> ignored.
>
startkey_docid is only useful when paging through a view where there are more rows emitted
for key X than your page size.
startkey_docid is subservient to the key. the internal implementation of collation looks like:
[key, docid]
so in your case
[ ["foo", "bar", "2010-06-10T12:14:35Z"], docid]
so the startkey_docid only has any effect when the key is an exact match for the emitted key.
I hope that helps.
Chris
> Any ideas?
>
> Thanks,
> Avi
>
> Avi Flax » Partner » Arc90 » http://arc90.com
> Kindling: Innovation through Collaboration » http://kindlingapp.com
|