Hi @Kushagra_Kesav, when I go over m103 I found the the video of Chapter one, lecture "Basic Commands " at 3:17 and lecture notes all gave the wrong format as:
db.runCommand(
{ "createIndexes": <collection> },
{ "indexes": [
{
"key": { "product": 1 }
},
{ "name": "name_index" }
]
}
)
but base on page https://docs.mongodb.com/manual/reference/command/createIndexes/
the correct syntax should be like below:
db.runCommand(
{ "createIndexes": "<collection name>" },
{ "indexes": [
{
"key": { "product": 1 },
"name": "name_index"
}
]
}
)
please take a look.
Thanks,
Junlei