Custom ordering of results in elasticsearch

Hi All,
I have a weird usecase, I have a .csv with "Name", "EmployeeId" and "Address" as the columns.
When using any query (say match_all), I need the data results to be displayed such that field "Name", "EmployeeId" and "Address", come in this order always.

Please guide me if ES has the said capability.

Best,
Divya

Elasticsearch speaks JSON.

As a result of a search query, it will give you back the document as you sent them.

You have to present the results as you wish in your application.

Sorry David, I could not understand "You have to present the results as you wish in your application", because I am sending the data in the same order only... "Name", "EmployeeId" and "Address"

Can you please brief me a bit on the same

What is the result you have today?

Hi David,
I am getting some random order, its not in order as the csv columns, neither the the reverse of the columns...

Thanks

I meant: can you share an example ?

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