I have a bunch of documents like:
{
_id: ObjectId(‘687f9779f79f1c7265796489’),
‘text:content’: {
data: ‘prefix:abc’
},
‘my:data’: null
}
and I’d like to update them all with something like:
db.default.updateMany({}, { $set: { “my:data”: “$text:content.data” }})
but I end up with my:data set to the literal value $text:content.data and not prefix:abc as desired. How can I do this? Thx.