you could try to specify multiple fields in multifield mapping with string type
(or type date) and different formats. Not sure if it is going to work though I
typically do this kind of staff in actual data. maybe something like:
"timestamp": {
"type": "date",
"format": "date",
"fields": {
"year": {
"type": "string", (or maybe date if string does not invoke formatter?)
"format": "yyyy",
},
"year-month": {
"type": "string", (or maybe date if string does not invoke formatter?)
"format": "yyyy-MM",
}
}
},
I would do in data (makes it bigger but gives you complete freedom to define
your dimension)
{
...
callStartTime:{timestamp:'full timestamp', time:'rounded to seconds',
weekOfMonth:3, month:11, year:2014}
}
then you can choose to not index timestamp at all and index the rest.
if your histogram is based on "absolute" date/time not on date/time relative to
today you could use term aggregation instead of ranges which should be faster
potentially much faster
--
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 [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/elasticsearch/2479246b-7c9f-45c7-b4d9-f19416575d1e%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.