Created
September 30, 2011 14:31
-
-
Save cedufca/1253912 to your computer and use it in GitHub Desktop.
ElasticSearch wildcard score
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
### Query without wildcard | |
query: | |
bool: | |
should: | |
- field: | |
name: | |
query: linguagem | |
boost: 10.0 | |
- field: | |
description: | |
query: linguagem | |
boost: 5.0 | |
- field: | |
address: | |
query: linguagem | |
boost: 5.0 | |
- field: | |
programs: | |
query: linguagem | |
boost: 1.0 | |
minimum_number_should_match: 1 | |
highlight: | |
number_of_fragments: 0, | |
fields: { name: {}, description: {}, address: {}, programs: {} } | |
### Result | |
took: 2 | |
timed_out: false | |
_shards: | |
total: 5 | |
successful: 5 | |
failed: 0 | |
hits: | |
total: 2 | |
max_score: 0.021433933 | |
hits: | |
- _index: events | |
_type: event | |
_id: "49" | |
_score: 0.021433933 | |
_source: | |
id: 49 | |
name: RubyConf 2011 | |
description: Rubistas de todas as partes se encontram para discutir a linguagem e suas ferramentas | |
address: "S\xC3\xA3o Paulo" | |
programs: "Rails 3.1: 1. Agilidade com RVM: Rvm. Cucumber, o pepino: Pepino" | |
highlight: | |
description: | |
- Rubistas de todas as partes se encontram para discutir a <em>linguagem</em> e suas ferramentas | |
- _index: events | |
_type: event | |
_id: "50" | |
_score: 0.0153546175 | |
_source: | |
id: 50 | |
name: "ExpoGest\xC3\xA3o 3002" | |
description: Evento de tecnologia | |
address: Joinville / Santa Catarina | |
programs: "Dom\xC3\xB3tica: Tica. Linguagem neural: Neural" | |
highlight: | |
programs: | |
- "Dom\xC3\xB3tica: Tica. <em>Linguagem</em> neural: Neural" | |
### Query *with* wildcard | |
query: | |
bool: | |
should: | |
- field: | |
name: | |
query: linguagem* | |
boost: 10.0 | |
- field: | |
description: | |
query: linguagem* | |
boost: 5.0 | |
- field: | |
address: | |
query: linguagem* | |
boost: 5.0 | |
- field: | |
programs: | |
query: linguagem* | |
boost: 1.0 | |
minimum_number_should_match: 1 | |
highlight: | |
number_of_fragments: 0, | |
fields: { name: {}, description: {}, address: {}, programs: {} } | |
### Result | |
took: 3 | |
timed_out: false | |
_shards: | |
total: 5 | |
successful: 5 | |
failed: 0 | |
hits: | |
total: 2 | |
max_score: 0.25 | |
hits: | |
- _index: events | |
_type: event | |
_id: "50" | |
_score: 0.25 | |
_source: | |
id: 50 | |
name: "ExpoGest\xC3\xA3o 3002" | |
description: Evento de tecnologia | |
address: Joinville / Santa Catarina | |
programs: "Dom\xC3\xB3tica: Tica. Linguagem neural: Neural" | |
highlight: | |
programs: | |
- "Dom\xC3\xB3tica: Tica. <em>Linguagem</em> neural: Neural" | |
- _index: events | |
_type: event | |
_id: "49" | |
_score: 0.25 | |
_source: | |
id: 49 | |
name: RubyConf 2011 | |
description: Rubistas de todas as partes se encontram para discutir a linguagem e suas ferramentas | |
address: "S\xC3\xA3o Paulo" | |
programs: "Rails 3.1: 1. Agilidade com RVM: Rvm. Cucumber, o pepino: Pepino" | |
highlight: | |
description: | |
- Rubistas de todas as partes se encontram para discutir a <em>linguagem</em> e suas ferramenta | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment