I was looking for equivalent of splunk query (i.e. get raw data , then do aggregation on top of that)
index=some_data | stats count by hostname
The above will aggregate all the data by hostname and shows the data in nice looking GUI table && charts.
How to do the above equivalent in KQL/Kibana?
(PS: I don't want to use the mouse clicks to do aggregation but everything as a query)