Splunk Search

Filtering specific digit at the end of a field value

brennson90
Path Finder

Hi community,

i have the following tstats output
"| tstats count WHERE fromzone="*INTRANET*" index=*_*_* by index source getport"

The getport field is for different indexes always 5 digits long for e.g. (index A has Port 22001, index B has 25003, index C has 35002)
Now i want to filter out all field values from the field getport without the "1" at the end.

Thanks for your help!

Labels (3)
0 Karma
1 Solution

kamlesh_vaghela
SplunkTrust
SplunkTrust

@brennson90 

Are you looking for this?

 

YOUR_SEARCH
| search getport!="*1"

 OR

YOUR_SEARCH
| regex "getport"!="\d{4}1"

KV

View solution in original post

brennson90
Path Finder

It, works
thanks

0 Karma

kamlesh_vaghela
SplunkTrust
SplunkTrust

@brennson90 

Are you looking for this?

 

YOUR_SEARCH
| search getport!="*1"

 OR

YOUR_SEARCH
| regex "getport"!="\d{4}1"

KV

Get Updates on the Splunk Community!

Database Performance Sidebar Panel Now on APM Database Query Performance & Service ...

We’ve streamlined the troubleshooting experience for database-related service issues by adding a database ...

IM Landing Page Filter - Now Available

We’ve added the capability for you to filter across the summary details on the main Infrastructure Monitoring ...

Dynamic Links from Alerts to IM Navigators - New in Observability Cloud

Splunk continues to improve the troubleshooting experience in Observability Cloud with this latest enhancement ...