couchdb-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From James Dingwall <>
Subject Eliminate keys during reduce?
Date Wed, 26 Feb 2014 15:39:20 GMT

I have a reduce function which is queried with 
?reduce=true&group_level=1.  In some cases the value is interesting and 
other cases not.  Is it possible to delete the keys from the result 
which are not interesting?  I have tried returning null and undefined in 
these cases but that does not seem to work. At the moment I'm filtering 
out the non-interesting cases with a list function but that seems to be 
an unnecessary layer and not necessarily scalable as the size of the 
database increases.  The only other solution is for the code consuming 
the result to do the filter but ideally I would like the result to 
shrink to 0 rows when it is all uninteresting.


View raw message