Return-Path: Delivered-To: apmail-jakarta-lucene-user-archive@apache.org Received: (qmail 340 invoked from network); 5 Mar 2002 10:40:38 -0000 Received: from unknown (HELO nagoya.betaversion.org) (192.18.49.131) by daedalus.apache.org with SMTP; 5 Mar 2002 10:40:38 -0000 Received: (qmail 16730 invoked by uid 97); 5 Mar 2002 10:40:49 -0000 Delivered-To: qmlist-jakarta-archive-lucene-user@jakarta.apache.org Received: (qmail 16677 invoked by uid 97); 5 Mar 2002 10:40:48 -0000 Mailing-List: contact lucene-user-help@jakarta.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Subscribe: List-Help: List-Post: List-Id: "Lucene Users List" Reply-To: "Lucene Users List" Delivered-To: mailing list lucene-user@jakarta.apache.org Received: (qmail 16666 invoked from network); 5 Mar 2002 10:40:47 -0000 content-class: urn:content-classes:message Subject: Adding multiple paths to a document MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable X-MimeOLE: Produced By Microsoft Exchange V6.0.4712.0 Date: Tue, 5 Mar 2002 11:40:44 +0100 Message-ID: <975A4194C167384EB2F65FF61808FB5F052085@trygve.Oslo-API.api.no> X-MS-Has-Attach: X-MS-TNEF-Correlator: Thread-Topic: Adding multiple paths to a document Thread-Index: AcHEMjRh8xbyIpI1SBu8vfs6VXYpfA== From: "Grim Hegland Iversen" To: X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N I am looking at using lucene to index a large set of documents. In order to be able to search a subset of documents, I've added a "path"-field to each document (indexed, not stored, not tokenized). Using a prefix-query seems to work fine.=20 My problem: Our documents can have several different paths pointing to the same document, so I would like to add several paths to each document, and be able to find the document using different prefix-queries. So my question: Is this accomplished simply by adding several fields to the document by the same name ? doc.add(new Field("path", "/test/path1/misc"),false,true,false)); doc.add(new Field("path", "/test/path2/misc"),false,true,false)); This seems to work, but I would like to know if it is the right way. -- To unsubscribe, e-mail: For additional commands, e-mail: