Files
mongo/jstests/core/query/array/array1.js

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

16 lines
314 B
JavaScript
Raw Normal View History

const coll = db.array1;
coll.drop();
const x = {
a: [1, 2]
};
assert.commandWorked(coll.insert({a: [[1, 2]]}));
assert.eq(1, coll.find(x).count());
assert.commandWorked(coll.insert(x));
assert.eq(2, coll.find(x).count());
assert.commandWorked(coll.createIndex({a: 1}));
assert.eq(2, coll.find(x).count());