Getting Data In

epoch _time conversion

_dave_b
Communicator

Hello,

I'm trying to retrieve a readable time value from a time stamp, so I ran this command:

eval "Time of most recent Update"=tostring(_time,"duration") 

and I get back a value like this:

16723+03:58:46.647379

when _time is originally 2015 10-14 23:10:54.111
This looks suspect to me. Is 16723+03:58:46.647379 the correct value? How do I interpret it?

Thanks

0 Karma
1 Solution

sundareshr
Legend

duration is time in seconds. For a human readable time format, look at strftime() In you example strftime(_time, "%Y %M%D") would give you 2015 10 14.

View solution in original post

0 Karma

sundareshr
Legend

duration is time in seconds. For a human readable time format, look at strftime() In you example strftime(_time, "%Y %M%D") would give you 2015 10 14.

0 Karma

_dave_b
Communicator

Thanks! That helped a lot

0 Karma
Get Updates on the Splunk Community!

Introducing the 2024 SplunkTrust!

Hello, Splunk Community! We are beyond thrilled to announce our newest group of SplunkTrust members!  The ...

Introducing the 2024 Splunk MVPs!

We are excited to announce the 2024 cohort of the Splunk MVP program. Splunk MVPs are passionate members of ...

Splunk Custom Visualizations App End of Life

The Splunk Custom Visualizations apps End of Life for SimpleXML will reach end of support on Dec 21, 2024, ...