couchdb-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Chris Anderson <jch...@apache.org>
Subject Re: Asking for include_docs=false on a reduce view
Date Thu, 23 Apr 2009 14:19:45 GMT
On Thursday, April 23, 2009, Brian Candler <B.Candler@pobox.com> wrote:
> Minor API issue: I cannot specify include_docs=false where I also have
> reduce=true
>

This ought to be a tiny patch. I'd say go for it, B.


> That is, it's the fourth case I'm thinking of here:
>
>   reduce=false&include_docs=true    # OK
>   reduce=false&include_docs=false   # OK
>   reduce=true&include_docs=true     # Nonsensical, rejected OK
>   reduce=true&include_docs=false    # << Rejected, but legitimate?
>
> The reason I raise this is that it's quite useful to be able to set some
> defaults for a view, e.g. {:include_docs=>true, :reduce=>false}, and then
> be able to override them later.
>
> So I have to complicate things a bit on the client side - I can't just merge
> the overriding options, I have to check for :reduce=>true and remove
> :include_docs if it is set.
>
> Regards,
>
> Brian.
>

-- 
Chris Anderson
http://jchrisa.net
http://couch.io

Mime
View raw message