How to replace substring in mongodb document
db.media.find({mediaContainer:”ContainerS3″}).forEach(function(e,i) { e.url=e.url.replace(“//a.n.com”,”//b.n.com”); db.media.save(e); });
db.media.find({mediaContainer:”ContainerS3″}).forEach(function(e,i) { e.url=e.url.replace(“//a.n.com”,”//b.n.com”); db.media.save(e); });