Splunk Search

iam receiving a message unbalanced quotes , i tried using back slash

pavanraghav
Explorer
 | eval e="$time_token.earliest$", l=$time_token.latest$"| eval e=case(match(e,"^\d+$"),e,e="" OR e="now" , "0" , true(), relative_time(now(),e)) | eval l=case(match(l,"^\d+$"),l,l="" OR l="now" , "2145916800", true(), relative_time(now(),l)) 
Tags (1)
0 Karma
1 Solution

renjith_nair
Legend

@pavanraghav ,

In your search above, you are missing a " in I=$time_token.latest$"

Also , please use the Code Sample to add your search snippets. I edited it for now

Happy Splunking!

View solution in original post

0 Karma

arjunpkishore5
Motivator

your missing a quote in your eval

| eval e="$time_token.earliest$", l="$time_token.latest$"
| eval e=case(match(e,"^\d+$"),e,e="" or e="now" , "0" , true(), relative_time(now(),e)) 
| eval l=case(match(l,"^\d+$"),l,l="" or l="now" , "2145916800", true(), relative_time(now(),l)) 
0 Karma

pavanraghav
Explorer

thanks arjun

0 Karma

renjith_nair
Legend

@pavanraghav ,

In your search above, you are missing a " in I=$time_token.latest$"

Also , please use the Code Sample to add your search snippets. I edited it for now

Happy Splunking!
0 Karma

pavanraghav
Explorer

thanks renjith

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, ...