- Mark as New
- Bookmark Message
- Subscribe to Message
- Mute Message
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
balash1979
Path Finder
09-05-2019
01:58 PM
Trying to parse the following line:
newCount 20 OldCount 10
The following is my splunk query:
index="server" | rex "newCount"\s+"(?\w+)" | rex "OldCount"\s+"(?\w+)" | search newcount>0 | search oldcount>0 | timechart span=1h count
How can i ensure that irrespective of whether newCount or oldCount is greater than 0, my splunk query will catch that ?
1 Solution
- Mark as New
- Bookmark Message
- Subscribe to Message
- Mute Message
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content

richgalloway

SplunkTrust
09-05-2019
02:21 PM
Use OR
.
index="server" | rex "newCount"\s+"(?\w+)" | rex "OldCount"\s+"(?\w+)" | search newcount>0 OR oldcount>0 | timechart span=1h count
---
If this reply helps you, Karma would be appreciated.
If this reply helps you, Karma would be appreciated.
- Mark as New
- Bookmark Message
- Subscribe to Message
- Mute Message
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content

richgalloway

SplunkTrust
09-05-2019
02:21 PM
Use OR
.
index="server" | rex "newCount"\s+"(?\w+)" | rex "OldCount"\s+"(?\w+)" | search newcount>0 OR oldcount>0 | timechart span=1h count
---
If this reply helps you, Karma would be appreciated.
If this reply helps you, Karma would be appreciated.
