Hello,
i can't get this date parsed correctly
20220113T21:00:18.965901
date {
match => ["fill_date", "yyyMMdd'T'HH:mm:ss.SSSSSS"]
target => "@timestamp"
}
Best
Hello,
i can't get this date parsed correctly
20220113T21:00:18.965901
date {
match => ["fill_date", "yyyMMdd'T'HH:mm:ss.SSSSSS"]
target => "@timestamp"
}
Best
Hi,
you should try without single quotting.
something like "yyyyMMddTHH:mm:ss"
Thanks grumo35 but it doesn't work
date {
match => ["fill_date", "yyyMMddTHH:mm:ss.SSSSSS"]
target => "@timestamp"
}
It throws an error
This format starts with 3 y
s but 4 y
s is correct.
It worked fine for me.
PUT /test_datetime/
{
"mappings": {
"properties": {
"date": {
"type": "date",
"format": ["yyyyMMdd'T'HH:mm:ss.SSSSSS"]
}
}
}
}
POST /test_datetime/_doc
{
"date": "20220113T21:00:18.965901"
}
-> ok
POST /test_datetime/_doc
{
"date": "20220113T21:00:18"
}
-> error
GET /test_datetime/_search
Many thanks Tomo_M & Grumo35 it was my fault, yyyy instead of yyy
Best
This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
© 2020. All Rights Reserved - Elasticsearch
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.