Getting Data In

How to extract time log from JSON data for event _time?

anantdeshpande
Path Finder

Team,

In my JSON data, there is below line which I want to be my event time (_time).

"eventDateTime" : "2017-24-08T05:19:54.500-05:00",

My props.conf has below entry. I am not sure what to write for last (-05:00). Please help.

TIME_FORMAT=%Y-%d-%mT%H:%M:%S.3N
TIME_PREFIX="eventDateTime" :

0 Karma

cmerriman
Super Champion
0 Karma

gcusello
SplunkTrust
SplunkTrust

HI anantdeshpande,
-05.00 is the timezone, put %z at the end of your TIME_FORMAT

TIME_FORMAT=%Y-%d-%mT%H:%M:%S.3N-%z

Check if brackets are in or out of your time field.

Bye.
Giuseppe

0 Karma
Get Updates on the Splunk Community!

Stay Connected: Your Guide to May Tech Talks, Office Hours, and Webinars!

Take a look below to explore our upcoming Community Office Hours, Tech Talks, and Webinars this month. This ...

They're back! Join the SplunkTrust and MVP at .conf24

With our highly anticipated annual conference, .conf, comes the fez-wearers you can trust! The SplunkTrust, as ...

Enterprise Security Content Update (ESCU) | New Releases

Last month, the Splunk Threat Research Team had two releases of new security content via the Enterprise ...