Splunk Search

Which value does the dedup command keep?

Simeon
Splunk Employee
Splunk Employee

I am running the dedup command for my ip_address field and I want to know the value returned by the command. Is it the last value seen, first value seen, something random? My search looks like this;

sourcetype=firewall_log | dedup ip_address
Tags (2)
1 Solution

Simeon
Splunk Employee
Splunk Employee

The dedup command will return the first key value found for that particular field. This means the most recent in time, as splunk searches from latest to earliest. For example, in the search that dedups the ip_address value for your firewall log, you will see the most recent ip_address that has been logged to that source.

For more detail: http://www.splunk.com/base/Documentation/latest/SearchReference/Dedup

View solution in original post

Simeon
Splunk Employee
Splunk Employee

The dedup command will return the first key value found for that particular field. This means the most recent in time, as splunk searches from latest to earliest. For example, in the search that dedups the ip_address value for your firewall log, you will see the most recent ip_address that has been logged to that source.

For more detail: http://www.splunk.com/base/Documentation/latest/SearchReference/Dedup

Get Updates on the Splunk Community!

Shape the Future of Splunk: Join the Product Research Lab!

Join the Splunk Product Research Lab and connect with us in the Slack channel #product-research-lab to get ...

Auto-Injector for Everything Else: Making OpenTelemetry Truly Universal

You might have seen Splunk’s recent announcement about donating the OpenTelemetry Injector to the ...

[Puzzles] Solve, Learn, Repeat: Character substitutions with Regular Expressions

This challenge was first posted on Slack #puzzles channelFor BORE at .conf23, we had a puzzle question which ...