Return-Path: X-Original-To: apmail-couchdb-user-archive@www.apache.org Delivered-To: apmail-couchdb-user-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id F417CD194 for ; Tue, 6 Nov 2012 22:31:27 +0000 (UTC) Received: (qmail 18898 invoked by uid 500); 6 Nov 2012 22:31:26 -0000 Delivered-To: apmail-couchdb-user-archive@couchdb.apache.org Received: (qmail 18865 invoked by uid 500); 6 Nov 2012 22:31:26 -0000 Mailing-List: contact user-help@couchdb.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: user@couchdb.apache.org Delivered-To: mailing list user@couchdb.apache.org Received: (qmail 18856 invoked by uid 99); 6 Nov 2012 22:31:26 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 06 Nov 2012 22:31:26 +0000 X-ASF-Spam-Status: No, hits=2.2 required=5.0 tests=HTML_MESSAGE,RCVD_IN_DNSWL_LOW,SPF_NEUTRAL X-Spam-Check-By: apache.org Received-SPF: neutral (nike.apache.org: local policy) Received: from [209.85.217.180] (HELO mail-lb0-f180.google.com) (209.85.217.180) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 06 Nov 2012 22:31:18 +0000 Received: by mail-lb0-f180.google.com with SMTP id ge1so786304lbb.11 for ; Tue, 06 Nov 2012 14:30:58 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=mime-version:x-originating-ip:in-reply-to:references:from:date :message-id:subject:to:content-type:x-gm-message-state; bh=+VGfuj4IdULvhOwYBjQRkxhEi4Cge28d55FO3i9eIoY=; b=CIFXqdbgizenuwx8+WX83hnNsnACf7X9taNYd8z36JMI6O4yIK/4oSuvN/HQXdnzSE x4uVk9WA3ryu/FxpzJQhKgqxNx1jqZrO4pL9NYz2FTgw04XbYC3UXil5dPxculO4Azg6 FtTbtyK2NziFpz/+3duVJt5WuR7Kl/CK0KNG36fp9qZMVS+Gr1YujYBxioD60xNAlwxQ 21SnCrYPpCQFB2a7saIkf22in6LcddH0vNoRFHw2CHm/DkhmV6Q6PHtj3EEyYjLI75OT 3XKVIhUIXiy8yaWbwF5fXVsImvMM1vX14iRJnlhk9JD5lf3d1SqYRqehNtSfnJdeHoB0 4GPw== Received: by 10.152.47.97 with SMTP id c1mr2431307lan.37.1352241058178; Tue, 06 Nov 2012 14:30:58 -0800 (PST) MIME-Version: 1.0 Received: by 10.114.24.136 with HTTP; Tue, 6 Nov 2012 14:30:38 -0800 (PST) X-Originating-IP: [68.5.117.177] In-Reply-To: <1FB666F2DE7D4808A469855E74403FA4@cloudant.com> References: <028101cdbc69$cac8d600$605a8200$@charter.net> <1FB666F2DE7D4808A469855E74403FA4@cloudant.com> From: Mark Hahn Date: Tue, 6 Nov 2012 14:30:38 -0800 Message-ID: Subject: Re: Get all documents of a certain type. To: user@couchdb.apache.org Content-Type: multipart/alternative; boundary=bcaec554025aec66a204cddb27ca X-Gm-Message-State: ALoCoQlpCumLJw50yUXZzlYo7dwkSHsV+BZGBxHQj4CNuQV5DyM1qCgIfNBYuZykmSzJmwXQXlQl X-Virus-Checked: Checked by ClamAV on apache.org --bcaec554025aec66a204cddb27ca Content-Type: text/plain; charset=ISO-8859-1 A view that emitted (_id, sku) would be the easiest and most efficient way to do it. You wouldn't have to include_docs. On Tue, Nov 6, 2012 at 2:05 PM, Simon Metson wrote: > Hi, > You can query with ?startkey=product&endkey=productZZZZ&include_docs=true > to get all the product docs back. > > If they contain a lot more info than just the SKU's I'd make a view. > Cheers > Simon > > > On Tuesday, 6 November 2012 at 21:58, Kevin Burton wrote: > > > In my Couch database I have a mixture of documents. The documents that I > am > > interested in have an Id of 'product-xxxxxxx' or 'order-xxxxxx'. The > > "product" documents have a property of SKU that is a string. I would > like to > > form a query to get a list of all the product SKUs. Does this require a > view > > in the design document or can it be done all in one request? Thank you. > > > > --bcaec554025aec66a204cddb27ca--