Hi All. I'm new to ElasticSearch so am still trying to understand how it handles match queries. I have a bunch of docs in my index that have a array field, called keywordSearchTags" for keyword searching. So a document may look something like this:
{
"_index": "3ooij_costs",
"_type": "_doc",
"_id": "33295",
"_score": 1,
"_source": {
"projectLocation": "05-16-035-06W4",
"amount": 2962.46,
"Service Description": "Environmental - Execution",
"Service Provider": "Engineering",
"projectTemplate": "Default Template",
"budgetId": 8835,
"budgetName": "Budget 09/21/2016 21:19:42",
"createdOn": "2017-02-05T19:20:53.000Z",
"organizationId": 455,
"projectStatus": "Active",
"projectKey": "xq4rbtvl",
"workDate": "2017-01-17T00:00:00.000Z",
"Invoice #": "4058",
"createdBy": "John Doe",
"budgetAmount": 2962.46,
"Coding": "A7BY 7550/761",
"projectOwner": "Energy Corp",
"projectAssignee": "Energy Ltd",
"projectName": "100/05-16-035-06W4/00",
"fiscalYear": 2017,
"projectId": 12601,
"keywordSearchTags": [
"John Doe",
"Budget 09/21/2016 21:19:42",
"100/05-16-035-06W4/00",
"Energy Corp",
"Energy Ltd",
"Default Template",
"05-16-035-06W4"
]
}
}
If I do a match query against keywrdSearchTags, say, the words "Energy Ltd." I will get the right number of relevant matches. But if I search for a code like "100/05-16-035-06W4/00", I get a huge number of results back, rather than something that matches my string. These sorts of codes are used by our clients to find a location, so they should be as accurate as possible. Yet, I would get 800 hits with many of them not matching this code at all. Is there something that's different strings with numbers like this that is handled differently? How can I get a more accurate result?
thanks