FAQ
I am trying to execute below query against Solr

q=cancer care facilities
&debugQuery=true
&defType=edismax
&bf=query({!lucene df=article q.op=AND v=$q},0)

but it throws below error after execution,

org.apache.solr.common.SolrException: undefined field: "v"
  at org.apache.solr.schema.IndexSchema.getField(IndexSchema.java:1229)
  at
org.apache.solr.search.FunctionQParser.parseValueSource(FunctionQParser.java:377)
  at org.apache.solr.search.FunctionQParser.parse(FunctionQParser.java:80)
  at org.apache.solr.search.QParser.getQuery(QParser.java:141)
  at
org.apache.solr.search.ExtendedDismaxQParser.getBoostFunctions(ExtendedDismaxQParser.java:471)
  at
org.apache.solr.search.ExtendedDismaxQParser.parse(ExtendedDismaxQParser.java:202)
  at org.apache.solr.search.QParser.getQuery(QParser.java:141)
  at
org.apache.solr.handler.component.QueryComponent.prepare(QueryComponent.java:157)
  at
org.apache.solr.handler.component.SearchHandler.handleRequestBody(SearchHandler.java:236)
  at
org.apache.solr.handler.RequestHandlerBase.handleRequest(RequestHandlerBase.java:143)


But when we try same thing with Parameter dereferencing for bf then it works
as expected,

q=cancer care facilities
&debugQuery=true
&defType=edismax
&bf=$my_func
&my_func=query({!lucene df=article q.op=AND v=$q},0)


What can be a reason for this? How can we pass function directly as a bf
parameter ?



--
View this message in context: http://lucene.472066.n3.nabble.com/Can-not-pass-function-query-directly-as-a-bf-parameter-tp4281986.html
Sent from the Solr - User mailing list archive at Nabble.com.

Search Discussions

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
groupsolr-user @
categorieslucene
postedJun 13, '16 at 10:14a
activeJun 13, '16 at 10:14a
posts1
users1
websitelucene.apache.org...

1 user in discussion

Vijaymhaskar: 1 post

People

Translate

site design / logo © 2019 Grokbase