简体   繁体   English

在kibana-7.1.1中将日期格式从纪元更改为日期

[英]change date format from epoch to date in kibana-7.1.1

I am working on kibana-7.1.1. 我正在研究kibana-7.1.1。 I want it to be interactive. 我希望它是互动的。 I have one field of timestamp where field type is in epoch format. 我有一个时间戳字段,其中字段类型为epoch格式。

But I want to filter data in date format. 但我想以日期格式过滤数据。

I feel that I will have to insert data in date format rather than inserting in epoch format. 我觉得我必须以日期格式插入数据,而不是以epoch格式插入。 Is there any other way that I insert data in epoch format(because my original data file is in this format.) but still I can use filter on date format? 有没有其他方式我以epoch格式插入数据(因为我的原始数据文件是这种格式。)但我仍然可以使用日期格式的过滤器?

Yes, this is possible. 是的,这是可能的。 You possibly just need to change the mapping for this epoch field to date. 您可能只需要更改此epoch字段的映射到目前为止。

Elasticsearch is able to convert several date formats into a date mapped field just by guessing it. Elasticsearch能够通过猜测将几种日期格式转换为日期映射字段。 For special cases/date formats you're also able to specify a custom date pattern. 对于特殊情况/日期格式,您还可以指定自定义日期模式。

Please have a look on the documentation on this topic here: https://www.elastic.co/guide/en/elasticsearch/reference/current/date.html 请在此处查看有关此主题的文档: https//www.elastic.co/guide/en/elasticsearch/reference/current/date.html

Have Fun! 玩得开心!

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM