Splunk Dev

Search result in Join Not returning all the result in second result set

karunagaraprabh
Explorer

i have two queries where each queries return two rows as result . I am join two queries using left join which have common field as customerjobid.  when i run the quires, the result set fetch only second quires  result of first row.

Tags (1)
0 Karma
1 Solution

scelikok
SplunkTrust
SplunkTrust

Hi @karunagaraprabh ,

join command joins only first event on subsearch results that each main search result can join as default. You should use "max" parameter to match more results.

| join CustomerjobId type=left max=2

You can find more info about "max" parameter below;

https://docs.splunk.com/Documentation/Splunk/8.1.1/SearchReference/Join#Optional_arguments

 

If this reply helps you an upvote is appreciated.

If this reply helps you an upvote and "Accept as Solution" is appreciated.

View solution in original post

scelikok
SplunkTrust
SplunkTrust

Hi @karunagaraprabh ,

join command joins only first event on subsearch results that each main search result can join as default. You should use "max" parameter to match more results.

| join CustomerjobId type=left max=2

You can find more info about "max" parameter below;

https://docs.splunk.com/Documentation/Splunk/8.1.1/SearchReference/Join#Optional_arguments

 

If this reply helps you an upvote is appreciated.

If this reply helps you an upvote and "Accept as Solution" is appreciated.
Get Updates on the Splunk Community!

Splunk Observability Cloud's AI Assistant in Action Series: Auditing Compliance and ...

This is the third post in the Splunk Observability Cloud’s AI Assistant in Action series that digs into how to ...

Splunk Community Badges!

  Hey everyone! Ready to earn some serious bragging rights in the community? Along with our existing badges ...

What You Read The Most: Splunk Lantern’s Most Popular Articles!

Splunk Lantern is a Splunk customer success center that provides advice from Splunk experts on valuable data ...