How to bring a substring associated with the minimum date and time?

Hello everyone, I need help, I need to know what calculation I must do to register the name of the first person that is registered in a data set, considering date and time, in the example of the image it is a data set that registers messages, I need to calculate the Advisor_S field, where only the name of the advisor who gave the first answer will appear (Jesús David, he replied at 22:37:03)

Created At: date and time of the message

Conversation ID: Conversation ID

Direction: type of message, if it is Outbound or Inbound

Agent Name: Advisor that responds to each outbound message

Advisor_S: Advisor who answered the first outbound message (this is the field I need to calculate)

Hi,

can you try this?

ifelse(minOver(min(created at), [conversation_id], PRE_AGG) = created at, Agentname,NULL)

Maybe you need to add the minOver calculation in your dataset for this to work.

1 Like

Thank you very much, it really helped me… although I had to remove the “min” function