You are viewing a plain text version of this content. The canonical link for it is here.
Posted to solr-user@lucene.apache.org by stockm <st...@yahoo.de> on 2009/03/05 17:39:26 UTC

Query just for documents with full matching

Hello,

for example there are some documents:

Doc1 with title "Stop"
Doc2 with title "Stop watch"
Doc3 with title "Stop"
Doc4 with title "Watch"
Doc5 with title "Watch Stop"
Doc6 with title "Watch"

If I search for:  title:"Stop"
I will get Doc1, Doc3, Doc2, Doc5 (Doc2 and Doc5 with a lower score than
Doc1, Doc3).

My question: Is there a way/query to tell solr that I just want to have the
Docs with 100% identical titles (Doc1, Doc3)?

Thanks in advance,
stockm
-- 
View this message in context: http://www.nabble.com/Query-just-for-documents-with-full-matching-tp22355359p22355359.html
Sent from the Solr - User mailing list archive at Nabble.com.


Re: Query just for documents with full matching

Posted by Otis Gospodnetic <ot...@yahoo.com>.
Hi,

Index titles as "string" type.  But this will completely prevent you from being able to match "stop watch" when you search for "stop".  This is where field copying can help.


Otis
--
Sematext -- http://sematext.com/ -- Lucene - Solr - Nutch



----- Original Message ----
> From: stockm <st...@yahoo.de>
> To: solr-user@lucene.apache.org
> Sent: Thursday, March 5, 2009 11:39:26 AM
> Subject: Query just for documents with full matching
> 
> 
> Hello,
> 
> for example there are some documents:
> 
> Doc1 with title "Stop"
> Doc2 with title "Stop watch"
> Doc3 with title "Stop"
> Doc4 with title "Watch"
> Doc5 with title "Watch Stop"
> Doc6 with title "Watch"
> 
> If I search for:  title:"Stop"
> I will get Doc1, Doc3, Doc2, Doc5 (Doc2 and Doc5 with a lower score than
> Doc1, Doc3).
> 
> My question: Is there a way/query to tell solr that I just want to have the
> Docs with 100% identical titles (Doc1, Doc3)?
> 
> Thanks in advance,
> stockm
> -- 
> View this message in context: 
> http://www.nabble.com/Query-just-for-documents-with-full-matching-tp22355359p22355359.html
> Sent from the Solr - User mailing list archive at Nabble.com.