Splunk Search

Top 1 for already selected values using query

Digvijay
Path Finder

Digvijay_0-1626335823022.png

 

Current query :

index=salcus sourcetype= ticket_mgmt_rest source= http:ticket_mgmt_rest |rename "properties.o2-TroubleTicket-ReqId" as REQID | transaction REQID keepevicted=true | search eventcount=2 |table REQID duration |sort -duration

 

Now I want only top 1 record which has maximum duration , so how can I modify above query

Labels (1)
0 Karma
1 Solution

ITWhisperer
SplunkTrust
SplunkTrust
| sort 1 -duration

View solution in original post

ITWhisperer
SplunkTrust
SplunkTrust
| sort 1 -duration

Digvijay
Path Finder

thanks @ITWhisperer   for the quick and perfect reply

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