lucene-solr-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Alex Wang <aw...@crossview.com>
Subject Re: Weird Behavior When Querying Field of Type String
Date Wed, 12 May 2010 12:38:33 GMT
Thanks Erick for your response. Here is the debugQuery output:


<?xml version="1.0" encoding="UTF-8" ?>

-<%5Cl%20%22%22> <response>

-<%5Cl%20%22%22> <lst name="responseHeader">

<int name="status">0</int>

<int name="QTime">15</int>

-<%5Cl%20%22%22> <lst name="params">

<str name="debugQuery">true</str>

<str name="indent">on</str>

<str name="start">0</str>

<str name="q">productType:ProductBean</str>

<str name="rows">10</str>

<str name="version">2.2</str>

</lst>

</lst>

<result name="response" numFound="0" start="0" />

-<%5Cl%20%22%22> <lst name="debug">

-<%5Cl%20%22%22> <lst name="queryBoosting">

<str name="q">productType:ProductBean</str>

<null name="match" />

</lst>

<str name="rawquerystring">productType:ProductBean</str>

<str name="querystring">productType:ProductBean</str>

<str name="parsedquery">productType:ProductBean</str>

<str name="parsedquery_toString">productType:ProductBean</str>

<lst name="explain" />

<str name="QParser">LuceneQParser</str>

-<%5Cl%20%22%22> <lst name="timing">

<double name="time">0.0</double>

-<%5Cl%20%22%22> <lst name="prepare">

<double name="time">0.0</double>

-<%5Cl%20%22%22> <lst name="org.apache.solr.handler.component.QueryComponent">

<double name="time">0.0</double>

</lst>

-<%5Cl%20%22%22> <lst name="org.apache.solr.handler.component.FacetComponent">

<double name="time">0.0</double>

</lst>

-<%5Cl%20%22%22> <lst name="org.apache.solr.handler.component.MoreLikeThisComponent">

<double name="time">0.0</double>

</lst>

-<%5Cl%20%22%22> <lst name="org.apache.solr.handler.component.HighlightComponent">

<double name="time">0.0</double>

</lst>

-<%5Cl%20%22%22> <lst name="org.apache.solr.handler.component.StatsComponent">

<double name="time">0.0</double>

</lst>

-<%5Cl%20%22%22> <lst name="org.apache.solr.handler.component.QueryElevationComponent">

<double name="time">0.0</double>

</lst>

-<%5Cl%20%22%22> <lst name="org.apache.solr.handler.component.SpellCheckComponent">

<double name="time">0.0</double>

</lst>

-<%5Cl%20%22%22> <lst name="org.apache.solr.handler.component.DebugComponent">

<double name="time">0.0</double>

</lst>

</lst>

-<%5Cl%20%22%22> <lst name="process">

<double name="time">0.0</double>

-<%5Cl%20%22%22> <lst name="org.apache.solr.handler.component.QueryComponent">

<double name="time">0.0</double>

</lst>

-<%5Cl%20%22%22> <lst name="org.apache.solr.handler.component.FacetComponent">

<double name="time">0.0</double>

</lst>

-<%5Cl%20%22%22> <lst name="org.apache.solr.handler.component.MoreLikeThisComponent">

<double name="time">0.0</double>

</lst>

-<%5Cl%20%22%22> <lst name="org.apache.solr.handler.component.HighlightComponent">

<double name="time">0.0</double>

</lst>

-<%5Cl%20%22%22> <lst name="org.apache.solr.handler.component.StatsComponent">

<double name="time">0.0</double>

</lst>

-<%5Cl%20%22%22> <lst name="org.apache.solr.handler.component.QueryElevationComponent">

<double name="time">0.0</double>

</lst>

-<%5Cl%20%22%22> <lst name="org.apache.solr.handler.component.SpellCheckComponent">

<double name="time">0.0</double>

</lst>

-<%5Cl%20%22%22> <lst name="org.apache.solr.handler.component.DebugComponent">

<double name="time">0.0</double>

</lst>

</lst>

</lst>

</lst>

</response>


Alex Wang
CrossView Inc.
Mobile: 647-4093066
Email: awang@crossview.com<mailto:awang@crossview.com>
http://www.crossview.com<http://www.crossview.com/>
        [http://www.crossview.com/emails/signatures/signature.gif] <http://www.crossview.com/>

This message may contain confidential and/or privileged information. If you are not the addressee
or authorized to receive this for the addressee, you must not use, copy, disclose, or take
any action based on this message or any information herein. If you have received this message
in error, please advise the sender immediately by reply e-mail and delete this message.


On May 11, 2010, at 7:13 PM, Erick Erickson wrote:

What is the debug output of the query? That would shed some light on the
issue...

Best
Erick

On Tue, May 11, 2010 at 5:48 PM, Alex Wang <awang@crossview.com<mailto:awang@crossview.com>>
wrote:


Hi,

I am getting a weird behavior in my Solr (1.4) index:

I have a field defined as follows:

<field name="productType" type="string" indexed="true" stored="true" />

and in all my index documents, the value of this field is "ProductBean"
(without quotes).

However, in the Solr admin console, when I type in the following query, I
am expecting all my documents to come back, but Solr does not return any
results:

productType:ProductBean

Strangely, when I use the "Analysis" tool, it found a match as expected and
here is the output (with ProductBean highlighted):


Index Analyzer

org.apache.solr.schema.FieldType$DefaultAnalyzer {}

term position


1


term text


ProductBean


term type


word


source start,end


0,11


payload




Query Analyzer

org.apache.solr.schema.FieldType$DefaultAnalyzer {}

term position


1


term text


ProductBean


term type


word


source start,end


0,11


payload




Also, if I use wild card searches, I get results as expected
(productType:ProductBe*).

I have tried various things like clearing my browser cache, deleting the
data folder and re-index. None of them helps. Can someone please shed some
light here?

Thanks,

Alex




Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message