Questions tagged [dismax]

DisMax is an abbreviation of Disjunction Max, and is a popular query mode with Apache Solr.

DisMax is an abbreviation of Disjunction Max, and is a popular query mode with Apache Solr.

Out of the box, Solr used the standard Solr query parser which understands only syntactically correct boolean queries like "title:foo OR body:foo", it can only search one field by default, and it may throw an exception if you put in some characters it doesn't like. Therefore a new, more robust query mode was needed and the DisMax was born.

Disjunction refers to the fact that your search is executed across multiple fields, e.g. title, body and keywords, with different relevance weights.

Max means that if your word "foo" matches both title and body, the max score of these two (probably title match) is added to the score, not the sum of the two as a simple OR query would do. This gives more control over your ranking.

Have a look here for more details.

93 questions
2
votes
1 answer

How to use solrj with the DismaxRequestHandler?

Due to lack of proper documentation , I am unable to figure out on how to use the dismaxRequestHandler with SolrJ. On another note , is the standard request handler ,the default in SolrJ's implementation ?
A Null Pointer
  • 2,261
  • 3
  • 26
  • 28
2
votes
1 answer

Solr dismax boost query not working

I have some video titles stored in my solr index. I query based on title but want to have the rating to influence the score. The rating is a typical 5star rating. This rating is stored within solr along with the videos. I tried using the dismax…
Presnus
  • 723
  • 1
  • 6
  • 10
2
votes
1 answer

When to use edismax over dismax?

Solr supports dismax query parser and edismax query parser. How do we conclude when to use dismax and when edismax? When we should use edismax over dismax?
Yogita
  • 33
  • 1
  • 7
2
votes
4 answers

Solr search for exact phrase / substring

I am using solr for my work and it's excellent. However I am having trouble generating more elaborate search results. I am searching for products by their title, brand, gender, and category (dress shoes, jackets, etc). Brands live in a "Brands" DB…
mils
  • 1,878
  • 2
  • 21
  • 42
2
votes
1 answer

Solr dismax: How to specify a field to make a search with the parameter 'qs'?

I would to ask if someone knows how to specify a field using 'qs' parameter. I mean, for example, a have a document with this fields and content id: 1 name: Football keywords: football, goal, goalkeeper phrase_keywords: premier league, champions…
Zuljin
  • 85
  • 7
2
votes
1 answer

minimum_should_match in connection with dis-max-query

I am a neewby in elasticsearch as I just recently switched from Solr. I am now trying to convert an edismax query from my solrconfig to work with elasticsearch. Basically I want the terms to be searched in two fields at once, so I ended up with this…
linqu
  • 11,320
  • 8
  • 55
  • 67
1
vote
2 answers

Solr get calculated distance while using dismax

I'm starting to think that what I want to do is not possible but thought I would give this a try. I'm running Solr 3.5. I currently have two types of search: A basic spatial query which returns the calulated distance between two points in the score…
Carl
  • 680
  • 6
  • 22
1
vote
1 answer

how to use pf(Phrase Fields) and ps(Phrase Slop) of eDisMax Query Parser in solr?

What is Phrase Fields, Phrase Slop and Query Phrase Slop in eDisMax. I go through many website but not understand these with implementation. I want to know how query pass in solr using this and how output differs from each other If I have following…
1
vote
0 answers

ElasticSearch / Solr dis_max query skipping matching clauses

I have an Elasticsearch index on one shard, for which I'm running a [dis_max][4] query that, given some user details (First Name, Last Name, Date of Birth, Address, Phone, Username, Email etc.) queries users from an index combining a set of…
Andy186
  • 33
  • 6
1
vote
0 answers

configure dismax requesthandlar for boost a field

I want to apply boost for searching. i want that if a query term occur both in description,name than docs having query term in description field come high in search results. for this i configure dismax request handler as:
Romi
  • 4,833
  • 28
  • 81
  • 113
1
vote
2 answers

Elasticsearch dis_max query, return exact matching query

Lets assume i want to perform this query GET /_search { "query": { "dis_max" : { "queries" : [ { "term" : { "title" : "Quick pets" }}, { "term" : { "body" : "Quick pets" }} ], "tie_breaker" : 0.7 …
fhaase
  • 38
  • 3
1
vote
0 answers

Error while trying to use 'bf' on SOLR "Type mismatch: timestamp was indexed as SORTED_NUMERIC"

I wanted to use the 'Boost-Function' feature on my search (which in other cases and fields works just fine) in order to boost documents with higher 'timestamp value', in order to improve the relevancy score for these documents but not necessary,…
YotamL
  • 43
  • 5
1
vote
2 answers

How to query Solr to get the documents if it matches 50% of the query string?

I am using Solr 7.6 with the document structure is as follows: { "source_ln":"en", "source_text":"the sky is blue", "target_ln":"hi", "target_text":"आसमान नीला है", }, { "source_ln":"en", "source_text":"the sky is also called…
Vaibhav Raut
  • 95
  • 1
  • 1
  • 5
1
vote
1 answer

How do i using Query syntax in solrJ?

I need to implement this query in solrJ &sort=query($manu_sort,0) desc, query($manu_service_sort,0) desc, query($seller_sort,0) desc, _s_name asc, sku asc &manu_sort=ManufacturerName:"Service Champ" &manu_service_sort=ManufacturerName:"SERVICE…
pradeep murugan
  • 531
  • 1
  • 9
  • 18
1
vote
0 answers

EDISMAX - 0 weight for QF field

I came across an example EDISMAX query with 0 weight assigned to a field in qf. Example: Fields in index: title, body, keywords qf = title^100 body^0 keywords I understand providing no boost indicates default boost of 1. I however do not…
Sreejith Menon
  • 1,057
  • 1
  • 18
  • 27