Splunk Search

Can I do multiple joins with different fields

stavbergen
Explorer

Hello I have 3 sets of data and I want to join them all but they don't have the same common field, the trouble I'm having is linking table 2 to table 3.

Table 1
host, ip

Table 2
host, ip, user

Table 3
 user, location


Labels (2)
0 Karma
1 Solution

richgalloway
SplunkTrust
SplunkTrust

Yes, joins can be nested.

index=foo host=* ip=*
| join host, ip [ index=bar host=* ip=* user=*
  | join user [ index=baz user=* location=* ]
  ]
]
---
If this reply helps you, Karma would be appreciated.

View solution in original post

richgalloway
SplunkTrust
SplunkTrust

Yes, joins can be nested.

index=foo host=* ip=*
| join host, ip [ index=bar host=* ip=* user=*
  | join user [ index=baz user=* location=* ]
  ]
]
---
If this reply helps you, Karma would be appreciated.
Get Updates on the Splunk Community!

Developer Spotlight with Brett Adams

In our third Spotlight feature, we're excited to shine a light on Brett—a Splunk consultant, innovative ...

Index This | What can you do to make 55,555 equal 500?

April 2025 Edition Hayyy Splunk Education Enthusiasts and the Eternally Curious!  We’re back with this ...

Say goodbye to manually analyzing phishing and malware threats with Splunk Attack ...

In today’s evolving threat landscape, we understand you’re constantly bombarded with phishing and malware ...