Analyzer help for facet fields

Hi,
I have some facet fields I don't want analyzed. E.g.

"dates": [
"December 17, 1970"
]

The facet comes back only "december" in lowercase and without the rest. Of
course, this isn't useful.

I didn't see an analyzer in the docs that was just a "leave it as is"
analyzer.

Also, I don't want lowercase facets either.

Thanks for any help!

:slight_smile:

--
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/560f852c-5ee3-4a49-a318-29ed7f092ff5%40googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

So don't analyze at all the field! :slight_smile:
Set "index": "not_analyzed"

http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/mapping-core-types.html#string

--
David Pilato | Technical Advocate | Elasticsearch.com
@dadoonet | @elasticsearchfr

Le 16 décembre 2013 at 15:31:13, project2501 (darreng5150@gmail.com) a écrit:

Hi,
I have some facet fields I don't want analyzed. E.g.

"dates": [
"December 17, 1970"
]

The facet comes back only "december" in lowercase and without the rest. Of course, this isn't useful.

I didn't see an analyzer in the docs that was just a "leave it as is" analyzer.

Also, I don't want lowercase facets either.

Thanks for any help!

:slight_smile:

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/560f852c-5ee3-4a49-a318-29ed7f092ff5%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/etPan.52af1130.4353d0cd.6956%40MacBook-Air-de-David.local.
For more options, visit https://groups.google.com/groups/opt_out.

That works. Thank you. Still learning ES here. :slight_smile:

On Monday, December 16, 2013 9:41:52 AM UTC-5, David Pilato wrote:

So don't analyze at all the field! :slight_smile:
Set "index": "not_analyzed"

Elasticsearch Platform — Find real-time answers at scale | Elastic

--
David Pilato | Technical Advocate | Elasticsearch.com
@dadoonet https://twitter.com/dadoonet | @elasticsearchfrhttps://twitter.com/elasticsearchfr

Le 16 décembre 2013 at 15:31:13, project2501 (darre...@gmail.com<javascript:>)
a écrit:

Hi,
I have some facet fields I don't want analyzed. E.g.

"dates": [
"December 17, 1970"
]

The facet comes back only "december" in lowercase and without the rest. Of
course, this isn't useful.

I didn't see an analyzer in the docs that was just a "leave it as is"
analyzer.

Also, I don't want lowercase facets either.

Thanks for any help!

:slight_smile:

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/560f852c-5ee3-4a49-a318-29ed7f092ff5%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/a37360e4-2a65-43aa-9135-e774261d0ca8%40googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

Now there is a similar problem from this.

I set my document field to be "not_analyzed" for "places:

So I get

"places": [
"This_That",
"Here_and_There"
]

The facets come back exactly as you see them.

But now, I cannot search on those strings. I have to use string query.
When I do "places:"This_That" it says ZERO results.

If I do:

"places":"This That"

I get results as if "this OR that"

How can I indicate in a query string to not analyze this field? On a per
query basis?

On Monday, December 16, 2013 9:51:58 AM UTC-5, project2501 wrote:

That works. Thank you. Still learning ES here. :slight_smile:

On Monday, December 16, 2013 9:41:52 AM UTC-5, David Pilato wrote:

So don't analyze at all the field! :slight_smile:
Set "index": "not_analyzed"

Elasticsearch Platform — Find real-time answers at scale | Elastic

--
David Pilato | Technical Advocate | Elasticsearch.com
@dadoonet https://twitter.com/dadoonet | @elasticsearchfrhttps://twitter.com/elasticsearchfr

Le 16 décembre 2013 at 15:31:13, project2501 (darre...@gmail.com) a
écrit:

Hi,
I have some facet fields I don't want analyzed. E.g.

"dates": [
"December 17, 1970"
]

The facet comes back only "december" in lowercase and without the rest.
Of course, this isn't useful.

I didn't see an analyzer in the docs that was just a "leave it as is"
analyzer.

Also, I don't want lowercase facets either.

Thanks for any help!

:slight_smile:

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.
To view this discussion on the web visit
https://groups.google.com/d/msgid/elasticsearch/560f852c-5ee3-4a49-a318-29ed7f092ff5%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/6e462f96-e8a6-462c-bbad-30db61d0d5ec%40googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.