I want to convert the field of date from string to date, i try this code in my config file but it doesn't change in kibana..I don't know why! any help??
filter{
csv{
columns => ["car","date","dateEntree","dateSortie"]
separator => ","
}
date {
match => ["date", "dd/MM/YY"]
target => "date"
}
}
in the console when i run the config file he turn this
in my csv file i have column like this ;
Date
05.03.2020
05.03.2020
06.03.2020
.....
So i change in my file config like this : {
match => ["Date", "dd.MM.yyyy"]
target => "Date"
}
=====> i don't understand why he return in logstah this format ??
"Date" => 2020-03-04T23:00:00.000Z,
"Status" => "OK",
"@timestamp" => 2020-03-22T16:51:00.292Z,
If the field in elasticsearch is currently text, then if logstash sends a date elasticsearch will convert it to text as it indexes a document. If the field does not currently exist then elasticsearch will index it as a date. Try rolling over to a new index.
thank you very much for your answer
my problem is solved, thank you.
just I have another question about the input file in logstash in real time, can I ask my question please,maybe you can advice me!!
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.