Return-Path: Delivered-To: apmail-couchdb-commits-archive@www.apache.org Received: (qmail 59821 invoked from network); 10 Aug 2010 20:12:03 -0000 Received: from unknown (HELO mail.apache.org) (140.211.11.3) by 140.211.11.9 with SMTP; 10 Aug 2010 20:12:03 -0000 Received: (qmail 77966 invoked by uid 500); 10 Aug 2010 20:12:03 -0000 Delivered-To: apmail-couchdb-commits-archive@couchdb.apache.org Received: (qmail 77888 invoked by uid 500); 10 Aug 2010 20:12:03 -0000 Mailing-List: contact commits-help@couchdb.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@couchdb.apache.org Delivered-To: mailing list commits@couchdb.apache.org Received: (qmail 77880 invoked by uid 500); 10 Aug 2010 20:12:03 -0000 Delivered-To: apmail-incubator-couchdb-commits@incubator.apache.org Received: (qmail 77877 invoked by uid 99); 10 Aug 2010 20:12:03 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 10 Aug 2010 20:12:03 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=10.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.131] (HELO eos.apache.org) (140.211.11.131) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 10 Aug 2010 20:12:00 +0000 Received: from eosnew.apache.org (localhost [127.0.0.1]) by eos.apache.org (Postfix) with ESMTP id 51FCC61A; Tue, 10 Aug 2010 20:11:38 +0000 (UTC) MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable From: Apache Wiki To: Apache Wiki Date: Tue, 10 Aug 2010 20:11:37 -0000 Message-ID: <20100810201137.45154.60153@eosnew.apache.org> Subject: =?utf-8?q?=5BCouchdb_Wiki=5D_Trivial_Update_of_=22HTTP=5Fview=5FAPI=22_by?= =?utf-8?q?_Julian_Vassev?= X-Virus-Checked: Checked by ClamAV on apache.org Dear Wiki user, You have subscribed to a wiki page or wiki category on "Couchdb Wiki" for c= hange notification. The "HTTP_view_API" page has been changed by Julian Vassev. http://wiki.apache.org/couchdb/HTTP_view_API?action=3Ddiff&rev1=3D44&rev2= =3D45 -------------------------------------------------- = If a view contains both a map and reduce function, querying that view wil= l by default return the result of the reduce function. The result of the ma= p function only may be retrieved by passing ''reduce=3Dfalse'' as a query p= arameter. = - The ''include_docs'' option will include the associated document. Althoug= h, the user should keep in mind that there is a race condition when using t= his option. It is possible that between reading the view data and fetching = the corresponding document that the document has changed. If you want to al= leviate such concerns you should emit an object with a _rev attribute as in= ''emit(key, {"_rev": doc._rev})''. This alleviates the race condition but = leaves the possiblity that the returned document has been deleted (in which= case, it includes the ''"_deleted": true'' attribute). + The ''include_docs'' option will include the associated document. Althoug= h, the user should keep in mind that there is a race condition when using t= his option. It is possible that between reading the view data and fetching = the corresponding document that the document has changed. If you want to al= leviate such concerns you should emit an object with a _rev attribute as in= ''emit(key, {"_rev": doc._rev})''. This alleviates the race condition but = leaves the possibility that the returned document has been deleted (in whic= h case, it includes the ''"_deleted": true'' attribute). = The ''inclusive_end'' option controls whether the ''endkey'' is included = in the result. It defaults to true. =20