Multikey Indexes in MongoDB
MongoDB multikey indexes are used to collect and sort data from fields containing array values. MongoDB automatically creates a multikey index when a field that contains an array value is indexed.
Multikey indexes support efficient queries against array fields. It can be constructed over arrays that hold both scalar values(like strings, numbers, etc) and nested documents
MongoDB Multikey Indexes
Indexes are special data structures that store some information related to the documents such that it becomes easy for MongoDB to find the right data file. They also store the value of a specific field or set of fields, ordered by the value of the field as specified in the index.
MongoDB allows indexing a field that holds an array value by creating an index key for each element in the array, such type of indexing is called Multikey Indexes.