Splunk Search

How to filter duplicate KV entries?

RHogg
Engager

Hi guys,

I was wondering if someone could point me in the right direction with an issue I've been having.

Basically I have a search thats set to pull usernames from a KV lookup, the issue is theres "duplicate" entries in the lookup e.g.
Username and Username@email

Is there any way to stop the duplicate users from appearing in the search results? I seem to be at a bit of a dead end.

Thanks

Tags (3)
0 Karma
1 Solution

richgalloway
SplunkTrust
SplunkTrust

Those are not duplicates. If you want to filter out similar results then you need to modify your search to normalize the data. For example:

... | eval username = replace(username, "@.*", "")
---
If this reply helps you, Karma would be appreciated.

View solution in original post

richgalloway
SplunkTrust
SplunkTrust

Those are not duplicates. If you want to filter out similar results then you need to modify your search to normalize the data. For example:

... | eval username = replace(username, "@.*", "")
---
If this reply helps you, Karma would be appreciated.

RHogg
Engager

Just what I needed Rich, thanks very much! 🙂

0 Karma
Get Updates on the Splunk Community!

Routing logs with Splunk OTel Collector for Kubernetes

The Splunk Distribution of the OpenTelemetry (OTel) Collector is a product that provides a way to ingest ...

Welcome to the Splunk Community!

(view in My Videos) We're so glad you're here! The Splunk Community is place to connect, learn, give back, and ...

Tech Talk | Elevating Digital Service Excellence: The Synergy of Splunk RUM & APM

Elevating Digital Service Excellence: The Synergy of Real User Monitoring and Application Performance ...