Splunk Search

isuue with inputlookup file to expand multi values

james_n
Path Finder

Hi Experts,

I have a inputlookup file which consists of two fields i,e _time and names fields as shown below,

_time names
02/02/2020 user1
user2
08/02/2020 user1
user2
user3
10/02/2020 user2

I want to expand multi value filed i.e, names filed and show unique users list based on time, i tried |inputlookup filename.csv |stats values(names) as name |mvexpand name |dedup name |table name| sort - name but not worked for me,.
Please help on this, Thanks in advance.

0 Karma

kamlesh_vaghela
SplunkTrust
SplunkTrust

@james_n

Are you looking for this?

| inputlookup filename.csv | rex mode=sed "s/(\n)/,/g" field=names | eval names=split(names,",") | stats values(names) as name by _time
0 Karma
Get Updates on the Splunk Community!

What’s New in Splunk App for PCI Compliance 5.3.1?

The Splunk App for PCI Compliance allows customers to extend the power of their existing Splunk solution with ...

Extending Observability Content to Splunk Cloud

Register to join us !   In this Extending Observability Content to Splunk Cloud Tech Talk, you'll see how to ...

What's new in Splunk Cloud Platform 9.1.2312?

Hi Splunky people! We are excited to share the newest updates in Splunk Cloud Platform 9.1.2312! Analysts can ...