首页 > 代码库 > mongodb问题

mongodb问题

Generally in MongoDB, you would not use an auto-increment pattern for the _id field, or any field, because it does not scale for databases with large numbers of documents. Typically the default value ObjectId is more ideal for the _id.

文档上自己说,not scale for databases with large numbers of documents,自增的不适合有大数量documents的数据库

 

 

id的问题

mongodb问题