Issue with facets and not_analyzed in mapping


(Yury Kisliak) #1

Hello, could u please explain what is wrong.
http://pastebin.com/dMZudCsj
my config:

...
analysis:
analyzer:
default:
type: custom
tokenizer: standard
filter: [mam_ngram, lowercase]
filter:
mam_ngram:
type: nGram
side: front
min_gram: 3
max_gram: 4
token_chars: [letter, digit]

...

it's a query and ES output.
My mapping has not_analyzed but seems it does not work.
How to check where is issue ?

--
You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/7508f929-1e8b-47fa-b91f-3fd7faf6332e%40googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


(Ivan Brusic) #2

Judging by the output, the genre field is analyzed using the default
analyzer. Others can help debug if you provide your mapping. It is best to
use the get mapping API [1] since it shows what you actually have instead
of what you supplied at index creation.

Depending on your use case, you might benefit from using multi-fields. [2]

[1]
http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/indices-get-mapping.html

[2]
http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/_multi_fields.html

--
Ivan

On Tue, Mar 4, 2014 at 2:05 AM, Yury Kisliak fas.ysk@gmail.com wrote:

Hello, could u please explain what is wrong.
http://pastebin.com/dMZudCsj
my config:

...
analysis:
analyzer:
default:
type: custom
tokenizer: standard
filter: [mam_ngram, lowercase]
filter:
mam_ngram:
type: nGram
side: front
min_gram: 3
max_gram: 4
token_chars: [letter, digit]

...

it's a query and ES output.
My mapping has not_analyzed but seems it does not work.
How to check where is issue ?

--
You received this message because you are subscribed to the Google Groups
"elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an
email to elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit
https://groups.google.com/d/msgid/elasticsearch/7508f929-1e8b-47fa-b91f-3fd7faf6332e%40googlegroups.com
.
For more options, visit https://groups.google.com/groups/opt_out.

--
You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/CALY%3DcQCYZ3WBxpy%3DLPAB3r_bMG7TErq_gA2TAVMjBgSY4ge6Cw%40mail.gmail.com.
For more options, visit https://groups.google.com/groups/opt_out.


(Yury Kisliak) #3

Thanks Ivan, I've fixed issue. It was just in wrong mapping.

On Tuesday, March 4, 2014 8:29:00 PM UTC+1, Ivan Brusic wrote:

Judging by the output, the genre field is analyzed using the default
analyzer. Others can help debug if you provide your mapping. It is best to
use the get mapping API [1] since it shows what you actually have instead
of what you supplied at index creation.

Depending on your use case, you might benefit from using multi-fields. [2]

[1]
http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/indices-get-mapping.html

[2]
http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/_multi_fields.html

--
Ivan

On Tue, Mar 4, 2014 at 2:05 AM, Yury Kisliak <fas...@gmail.com<javascript:>

wrote:

Hello, could u please explain what is wrong.
http://pastebin.com/dMZudCsj
my config:

...
analysis:
analyzer:
default:
type: custom
tokenizer: standard
filter: [mam_ngram, lowercase]
filter:
mam_ngram:
type: nGram
side: front
min_gram: 3
max_gram: 4
token_chars: [letter, digit]

...

it's a query and ES output.
My mapping has not_analyzed but seems it does not work.
How to check where is issue ?

--
You received this message because you are subscribed to the Google Groups
"elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an
email to elasticsearc...@googlegroups.com <javascript:>.
To view this discussion on the web visit
https://groups.google.com/d/msgid/elasticsearch/7508f929-1e8b-47fa-b91f-3fd7faf6332e%40googlegroups.com
.
For more options, visit https://groups.google.com/groups/opt_out.

--
You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/3227db8d-3af5-417c-811a-664e43ffe944%40googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


(system) #4