suppose we have some data in mongodb
{
_id: ObjectId(7df78ad8902c)
title: 'MongoDB Overview',
description: 'MongoDB is no sql database',
by: 'tutorials point',
url: 'http://www.tutorialspoint.com',
tags: ['mongodb', 'database', 'NoSQL'],
likes: 100,
comments: 'this is a comment'
}
The user gives the input as "comment" and I want to remove that field from a specific document after searching the document by its id.