ES|QL Basic Help

Hello,

I did a STATS count = COUNT_DISTINCT(event.outcome) by host.name.
And it works, the only issue I wish I could keep the metadata information about the host?
Is there a way to do this??