Good point; I got caught up in the JavaScript issue and overlooked the
fundamental rule of querying couch: don't try to restrict the set of
documents in the map function. Just map the field you care about to a
key.  You can restrict the set of rows at query time.

As far as JSON, map and reduce functions never see JSON - it turns
into actual JavaScript objects before the functions are called.  Most
of the time you shouldn't have to do comparisons yourself, either -
just emit the values and query on them. Couch will do the necessary
comparison work.

On Wed, Jul 21, 2010 at 5:20 PM, Freddy Bowen <[email protected]> wrote:
> Find your doc in a view:
> http://yourcouch/db/_design/dd/_view/ex?startkey=[1,2,3,4,5]&endkey=[1,2,3,4,5]

or just ?key=[1,2,3,4,5].

-- 
Mark J. Reed <[email protected]>

Reply via email to