1st query: index="A" event_tag="event1" build_number=1 job_name=job1 type=completed
2nd query: index="B" event_tag="event2" build_number=1 job_name=job1
We have some events in indexA and some events in indexB ,how to combine these using common fileds are build_number and job_name.
What will the query
There are a few ways to combine searches, but the preferred way uses the general form:
(<<query 1>>) OR (<<query 2>>)
| stats values(*) as * by <<common fields>>
It is showing statistical information but not merging ,I want events from indexA and indexB together as single event .What will be the query and how can I know merging was happened .
I don't want table or statistics format
The join command should produce the format you seek, but you'll be unhappy with the performance. That's why the previous method I suggested is preferred.
<<query 1>>
| join <<common fields>> [ <<query 2>> ]
Join command is ok ,but how can know these two index events are combined,how can I see the combined data.Please give the proper answer
The indexed events are not combined. Indexed data is never changed so the events will forever remain separated. All we can do is correlate data from the indexes and display it in an appropriate format. You can, however, write the correlated data to a summary index using the collect command then fetch the events in the summary index to see a combined event.
But we have some events of job in indexA and some events of job in indexB ,suppose if we want to create a table all events of same job,how can we do that
My first answer said how to create a table with events of the same job from both indexes, but then you said you don't want a table.