I need to produce an extract to use as a data source for a third party application. The application needs the data in a csv format and required data from two sourcetypes. I can search for one sourcetype and then append the second search, but the tabled output is uneven. Here is an example - I need for two data sets to be merged.
Without a little bit of sample data, this is what I think would work (non-tested, kid approved)
index=os host=xxxxxxx sourcetype=puppet_facts OR sourcetype=package | multikv | stats latest(Domain) as Domain latest(...) as ... by host, NAME, VERSION
Replace the ... with the rest of your fields listed, one by one. This will give you an aggregation by NAME and VERSION and host. This also reduces the number of searches from 2 to 1, which is helpful for speed and optimization.