如何完成以下操作?mongodb數組匹配
db.test.save({a: [1,2,3]});
db.test.find({a: [1,2,3,4]}); //must match because it contains all required values [1, 2, 3]
db.test.find({a: [1,2]}); //must NOT match because the required value 3 is missing
我知道$ in和$ all,但他們的工作方式不同。