Database

[]

Query

db.collection.update({_id:"123"},{$setOnInsert:{anotherField:123},$currentDate:{timestamp:true}},{upsert:true})

Result