Re: Why are these two queries different?

2015-05-12 Thread Frank li
Thanks for your help. I figured it out. Just as you said. Appreciate your
help. Somehow forgot to reply your post.

On Wed, Apr 29, 2015 at 9:24 AM, Chris Hostetter hossman_luc...@fucit.org
wrote:


 : We did two SOLR qeries and they supposed to return the same results but
 : did not:

 the short answer is: if you want those queries to return the same results,
 then you need to adjust your query time analyzer forthe all_text field to
 not split intra numberic tokens on ,

 i don't know *why* exactly it's doing that, because you didn't give us the
 full details of your field/fieldtypes (or other really important info: the
 full request params -- echoParams=all -- and the documents matched by your
 second query, etc... https://wiki.apache.org/solr/UsingMailingLists )
 ... but that's the reason the queries are different as evident from the
 parsedquery output.


 : Query 1: all_text:(US 4,568,649 A)
 :
 : parsedquery: (+((all_text:us ((all_text:4 all_text:568 all_text:649
 : all_text:4568649)~4))~2))/no_coord,
 :
 : Result: numFound: 0,
 :
 : Query 2: all_text:(US 4568649)
 :
 : parsedquery: (+((all_text:us all_text:4568649)~2))/no_coord,
 :
 :
 : Result: numFound: 2,
 :
 :
 : We assumed the two return the same result. Our default operator is AND.



 -Hoss
 http://www.lucidworks.com/



Re: Why are these two queries different?

2015-04-29 Thread Chris Hostetter

: We did two SOLR qeries and they supposed to return the same results but
: did not:

the short answer is: if you want those queries to return the same results, 
then you need to adjust your query time analyzer forthe all_text field to 
not split intra numberic tokens on ,

i don't know *why* exactly it's doing that, because you didn't give us the 
full details of your field/fieldtypes (or other really important info: the 
full request params -- echoParams=all -- and the documents matched by your 
second query, etc... https://wiki.apache.org/solr/UsingMailingLists ) 
... but that's the reason the queries are different as evident from the 
parsedquery output.


: Query 1: all_text:(US 4,568,649 A)
: 
: parsedquery: (+((all_text:us ((all_text:4 all_text:568 all_text:649
: all_text:4568649)~4))~2))/no_coord,
: 
: Result: numFound: 0,
: 
: Query 2: all_text:(US 4568649)
: 
: parsedquery: (+((all_text:us all_text:4568649)~2))/no_coord,
: 
: 
: Result: numFound: 2,
: 
: 
: We assumed the two return the same result. Our default operator is AND.



-Hoss
http://www.lucidworks.com/


Why are these two queries different?

2015-04-27 Thread Frank li
We did two SOLR qeries and they supposed to return the same results but
didnot:

Query 1: all_text:(US 4,568,649 A)

parsedquery: (+((all_text:us ((all_text:4 all_text:568 all_text:649
all_text:4568649)~4))~2))/no_coord,

Result: numFound: 0,

Query 2: all_text:(US 4568649)

parsedquery: (+((all_text:us all_text:4568649)~2))/no_coord,


Result: numFound: 2,


We assumed the two return the same result. Our default operator is AND.