skip to Main Content

How to delete items by _id using mongodb

I have a problem trying to delete data by providing an array of id's (got error). I guess it has something to do with ObjectId. Could you help me fix it? User.deleteMany({ _id: { $in: ['638207a8b9ebc3ea8f276684', '63823ffe310abc61b4ee11a0', '63822a71319517d196af6d59' } })…

VIEW QUESTION
Back To Top
Search