Elasticsearch query output in table format

Hi ,
Is theare any way to get elasticsearch curl query output in table format or I need to write a wrapper script to process this output to archived the data in tabular format.
I have the following query:

curl -XGET "http://localhost:9200/event*/_search?pretty&filter_path=hits.hits._source&_source=jobid,event_time,status,message" -H 'Content-Type: application/json' -d' {"query": { "bool": { "must": [ { "match_all": {} }, { "match_phrase": { "jobid": { "query": "3404884" } } } ], "filter": [], "should": [], "must_not": [] } } }'

Now I want the output in table format like:

Jobid Status Event_Time Meaasage

xyz abc 2018-03-28 12:34:21 abc
asd ada

Is theare any way to get elasticsearch curl query output in table format

No. Not in elasticsearch.

But you can use Logstash if you want to extract data from elasticsearch and generate a TSV/CSV file for example.

Note that x-pack (commercial) also allows CSV exports from Kibana.

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.