This query returns 1 result
{
"query": {
"term": {
"sku": "testx.test"
}
}
}
This query returns 1 result
{
"query": {
"term": {
"sku": "test1"
}
}
}
My question is, how come I can only do an exact match query if the field
(keyword) has no numbers in it? I cant find documents where the sku field
is test1.test
This query returns 1 result
{
"query": {
"term": {
"sku": "testx.test"
}
}
}
This query returns 1 result
{
"query": {
"term": {
"sku": "test1"
}
}
}
My question is, how come I can only do an exact match query if the field (keyword) has no numbers in it? I cant find documents where the sku field is test1.test
Thanks David. I found my problem, there was more than one field in my
mapping which was done using Jackson via the java API. I was missing
an .endObject() call which meant the JSON generated was incorrect. The
interesting thing is that the mapping was successful for all fields above
the JSON error.
On Friday, December 28, 2012 3:59:41 PM UTC-5, Rick Devinsus wrote:
I have a mapping set up for a field called "sku". It is configured as
not_analyzed such that I can do exact matches on it
This query returns 1 result
{
"query": {
"term": {
"sku": "testx.test"
}
}
}
This query returns 1 result
{
"query": {
"term": {
"sku": "test1"
}
}
}
My question is, how come I can only do an exact match query if the field
(keyword) has no numbers in it? I cant find documents where the sku field
is test1.test
Apache, Apache Lucene, Apache Hadoop, Hadoop, HDFS and the yellow elephant
logo are trademarks of the
Apache Software Foundation
in the United States and/or other countries.