Splunk Dev

Two transactions results in one query

dwong2
New Member

....search
| eval View=case(like(publishId,"%U"),"unsubscribed",like(publishId,"%S"),"subscribed")
| transaction startswith="Enter" endswith="Exit" by deviceID View maxpause=300s
| table View accountExId deviceID action dateTime eventcount duration
| stats count(deviceID) as count by View

How can I get the transactions that are greater than 300s in duration as well?

Is there a way to show the transactions that are greater than 300s as well in one search?

Tags (1)
0 Karma

jkat54
SplunkTrust
SplunkTrust

....search
| eval View=case(like(publishId,"%U"),"unsubscribed",like(publishId,"%S"),"subscribed")
| transaction startswith="Enter" endswith="Exit" by deviceID View
| table View accountExId deviceID action dateTime eventcount duration
| stats count(deviceID) as count by View

The same search but remove maxpause=300

If you want to append see the other answer regarding append.

You could also do the above and use the duration field that is created by the transaction command. You can use eval and a case statement involving the duration field to creat low, medium, and high values for a field called severity... for example

0 Karma

adonio
Ultra Champion

can you kindly share a some sample data?
you might be able to get all transactions and duration just by removing the maxpause=300s attribute

0 Karma
Get Updates on the Splunk Community!

Built-in Service Level Objectives Management to Bridge the Gap Between Service & ...

Wednesday, May 29, 2024  |  11AM PST / 2PM ESTRegister now and join us to learn more about how you can ...

Get Your Exclusive Splunk Certified Cybersecurity Defense Engineer at Splunk .conf24 ...

We’re excited to announce a new Splunk certification exam being released at .conf24! If you’re headed to Vegas ...

Share Your Ideas & Meet the Lantern team at .Conf! Plus All of This Month’s New ...

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