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 jimmon <ji...@hifx.co.in> on 2012/07/02 11:42:06 UTC

solr error, cannot run PhraseQuery

http://172.17.100.16:8888/solr/collection1/select?q=name:(4U OR Cabs)^12.8
category:(4U OR Cabs)^1.6 subcategory:(4U OR Cabs)^0.4 description:(4U OR
Cabs)^0.1

the above query is throwing the the following error

field "subcategory" was indexed with Field.omitTermFreqAndPositions=true;
cannot run PhraseQuery (term=4)



subcategory field in schema.xml is like this

<field name="subcategory" type="text_en" required="true"
multiValued="true"/>

The only difference between name,category,subcategory & description is
subcategory is multivalued.
In the above solr query if we change subcategory:(4U OR Cabs) to 
subcategory:(5U OR Cabs) ,subcategory:(6U OR Cabs)  etc it works.

--
View this message in context: http://lucene.472066.n3.nabble.com/solr-error-cannot-run-PhraseQuery-tp3992469.html
Sent from the Solr - User mailing list archive at Nabble.com.

Re: solr error, cannot run PhraseQuery

Posted by Ahmet Arslan <io...@yahoo.com>.
> http://172.17.100.16:8888/solr/collection1/select?q=name:(4U
> OR Cabs)^12.8
> category:(4U OR Cabs)^1.6 subcategory:(4U OR Cabs)^0.4
> description:(4U OR
> Cabs)^0.1
> 
> the above query is throwing the the following error
> 
> field "subcategory" was indexed with
> Field.omitTermFreqAndPositions=true;
> cannot run PhraseQuery (term=4)
> 
> 
> 
> subcategory field in schema.xml is like this
> 
> <field name="subcategory" type="text_en" required="true"
> multiValued="true"/>

omitTermFreqAndPositions="true" is an option that field types can have. Positions are required for phrase queries. Do you have this option set in type="text_en" definition?