helloworld95
helloworld95

Reputation: 396

Create custom date format Elasticsearch

I'm looking to create a custom date format for Elasticsearch. I have data in formats like:

yyyy-MM-dd'T'HH:mm:ss
yyyy-MM-dd'T'HH:mm:ss.SSS
yyyy-MM-dd'T'HH:mm:ss.SSSSSS

Is it possible to create a single custom date format to accept all 3 forms of the datetimes?

Upvotes: 0

Views: 207

Answers (1)

Brijesh Shah
Brijesh Shah

Reputation: 172

You can add multiple formats by separating them with || as a separator. Here is the link to the official documentation with an example.

Upvotes: 1

Related Questions