How to create a single document with fields from multi documents

I have 4 documents with the below fields
{sessionid :1, callid:0001, service: 001}
{sessionid :1, state:login, city: hyderabad}
{sessionid :1, state:login, service:002}
{sessionid :1, state:logout, handset: mobile}

The requirement is to create single document with the all the latest status of the fields for the sessionid.

what is the aggregation to be used in continuous transform.

I am using scripted metric, but is top hit aggrgation is supported in transform ?


The docs here guide you on what aggregations are supported in the pivot - Create transform API | Elasticsearch Guide [7.12] | Elastic

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