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 15A904ACE for ; Thu, 19 May 2011 07:13:52 +0000 (UTC) Received: (qmail 82381 invoked by uid 500); 19 May 2011 07:13:49 -0000 Delivered-To: apmail-couchdb-user-archive@couchdb.apache.org Received: (qmail 82323 invoked by uid 500); 19 May 2011 07:13:44 -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 82315 invoked by uid 99); 19 May 2011 07:13:43 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 19 May 2011 07:13:43 +0000 X-ASF-Spam-Status: No, hits=-0.1 required=5.0 tests=HTML_MESSAGE,RCVD_IN_DNSWL_MED,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: local policy) Received: from [217.111.120.10] (HELO mailout02.rmx.de) (217.111.120.10) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 19 May 2011 07:13:37 +0000 Received: from [172.19.16.56] (HELO kdin03.retarus.de) by mailout02.rmx.de (CommuniGate Pro SMTP 5.2.13 _community_) with ESMTP id 196869014 for user@couchdb.apache.org; Thu, 19 May 2011 09:13:14 +0200 Received: from MAIL1.virtual-identity.net (mail.virtual-identity.com [195.226.108.10]) by kdin03.retarus.de (8.14.2/8.14.2/retarus.custom) with ESMTP id p4J7DADD017672 for ; Thu, 19 May 2011 09:13:11 +0200 X-MimeOLE: Produced By Microsoft Exchange V6.5 Content-class: urn:content-classes:message MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----_=_NextPart_001_01CC15F4.361C8487" Subject: emit attachments Date: Thu, 19 May 2011 09:13:10 +0200 Message-ID: <5BB0C5BEFECA11468B40FB51F7856E2304339A92@MAIL1.virtual-identity.net> X-MS-Has-Attach: X-MS-TNEF-Correlator: thread-topic: emit attachments thread-index: AcwV8m1vdhxSF54IQby220zwkP6mGA== From: "armin weisser" To: X-RMX-ID: 20110519-091311-p4J7DADD017672-0@kdin03 X-RMX-TRACE: 2011-05-19 09:13:12 RmxMSO@kdin03/mailcc11 [0.4s] 20110519-091311-p4J7DADD017672-0@kdin03 0:00:01 X-RMX-TRACE: 2011-05-19 09:13:11 KdIn@kdin03/mailcc10 [0.3s] 20110519-091311-p4J7DADD017672-0@kdin03 0:00:00 ------_=_NextPart_001_01CC15F4.361C8487 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Hi guys, =20 is there a way to emit the names of all _attachments?=20 =20 I found this one in the archive http://couchdb.markmail.org/search/?q=3D_attachments+emit+name#query:_att= a chments%20emit%20name+page:1+mid:ybbhvtlqa6rfqlgc+state:results but still I'm not sure how to emit a name of an attachment. =20 What I want to do is something like this =20 ~~~~~~~~~~~~~~~~~~~~~~~~~~snip function(doc) { for ( var i in doc._attachments) { emit([doc._id, 'attachment name'], doc._attachments[i]); } } ~~~~~~~~~~~~~~~~~~~~~~~~~~snap =20 where 'attachment name' should be replaced by the name of the attachment. =20 Cheers, =20 Armin ------_=_NextPart_001_01CC15F4.361C8487--