MongoDB’s {autoindented, true} reported an error, why?

  mongodb, question

Novice, just started to learn MongoDB, when creating the collection, I used the following command:
db.createCollection(“mycol”,{ autoIndexID: true })
Creation failed, prompt:

{
“ok” : 0,
“errmsg” : “The field ‘autoIndexID’ is not a valid collection option. Options: { autoIndexID: true }”,
“code” : 72,
“codeName” : “InvalidOptions”
}
Even if it is changed to false, it will fail. But if you don’t add this, you can succeed.

I would like to know why, thank God!

Try to read as many official documents as possible during your study. The content of many blogs is not rigorous:

autoIndexID --> autoIndexId

For reference.

Love MongoDB! Have Fun!


<–Please poke the left, it’s in April! MongoDB Chinese Community Shenzhen User Conference Begins Registration! Great gods gather!