Splunk Search

Splunk Time variable makes irritating search result with standard time Picker

GoodApprentice
New Member

Hallo,

i am trying to make a Dashboard that takes the time from reports of jobs.
That time is not the same as the time in Splunk. So the problem is that the time picker like 
"last 7 days" shows more than 7 days and the First and Last are not complete.
That is a Problem that i cant fix in the search code itself, i think.

Code: | eval NewTime=strptime(StartDateTZ,"%Y-%m-%d %H:%M:%S") | eval _time=NewTime | timechart span=1d@d count by TestName limit=0

Labels (3)
0 Karma

bowesmana
SplunkTrust
SplunkTrust

Can you elaborate - when you talk about jobs, do you mean

  • you are using loadjob to show the results of a saved search?
  • The data that is indexed in Splunk has a timestamp in an event that is NOT the timestamp Splunk has for the event?

If the former, then the time picker should not be relevant. If the latter, then that is likely a problem with your data ingestion.

The _time variable is a fixed field that is created when the data is ingested and is key to how you find data and is inextricably linked to the search window you specify with any time picker.

If the _time field is not the same as your StartDate value and if you are saying it SHOULD be the  same, then you will need to fix how that data is ingested and how the time is extracted during ingestion from that data.

You cannot expect to find StartDate values that fall outside the time window of your search range if that time does not equal the _time field. Splunk will not pull the data from its time based buckets unless you get that _time field right.

 

 

0 Karma
Career Survey
First 500 qualified respondents will receive a $20 gift card! Tell us about your professional Splunk journey.

Can’t make it to .conf25? Join us online!

Get Updates on the Splunk Community!

Splunk Lantern’s Guide to The Most Popular .conf25 Sessions

Splunk Lantern is a Splunk customer success center that provides advice from Splunk experts on valuable data ...

Unlock What’s Next: The Splunk Cloud Platform at .conf25

In just a few days, Boston will be buzzing as the Splunk team and thousands of community members come together ...

Index This | How many sevens are there between 1 and 100?

August 2025 Edition Hayyy Splunk Education Enthusiasts and the Eternally Curious!  We’re back with this ...