Data conversion

Hello good morning.

Could you please help me, I need to convert the values ​​of a numeric field to a string, massively in a collection.

Example:

idEmpleado: NumberLong(22)
to
idEmpleado: “22”

When idEmpleado has different values

Beforehand thank you very much.

Update statement in aggregate form to use the $toString:

You may want to work in batches if you need to limit server usage while it’s running.