Splunk Search

How to extract string value and use comparison operators in a search?

akash_akkis
New Member

Hi I am new to splunk
I wanted to extract data from logs that have a particular string with a value and only return data where the extracted value is 100 or greater.

ID: 2999
Payload: {"Audit":{"__queryElapsedTime":"267","__requestReceived":"2014.09.04 06:01:04.560
Address: sdfjkjsdljsjdjjkljsd";k;lklsdk

Here is my logs I wanted to search ID , Payload , Address and list in table

ID Address Payload
2999 sdjsdjj;'lkdfj;ksfdk {"Audit":{"queryElapsedTime":"267","requestReceive

Please help me I am stuck with prod issue.

0 Karma

gfuente
Motivator

Hello

Try this:

your base search ... | rex "queryElapsedTime\"\:\"(?<queryelapsedtime>\d+)\"" | search queryelapsedtime > 99 | stats count, values(queryelapsedtime) by _time

Regards

0 Karma

akash_akkis
New Member

Hi gluente Thanks for your answer its working fine now I need the above sample which is edited Please give me some trick

0 Karma
Get Updates on the Splunk Community!

Brains, Bytes, and Boston: Learn from the Best at .conf25

When you think of Boston, you might picture colonial charm, world-class universities, or even the crack of a ...

Splunk AppDynamics Agents Webinar Series

Mark your calendars! On June 24th at 12PM PST, we’re going live with the second session of our Splunk ...

SplunkTrust Application Period is Officially OPEN!

It's that time, folks! The application/nomination period for the 2025 SplunkTrust is officially open! If you ...