问题描述
我是 MongoDB 的新手.我在 http:///docs.mongodb.org/manual/faq/fundamentals/.
I am new to MongoDB. I read that MongoDB does not support multi-document transactions
here http://docs.mongodb.org/manual/faq/fundamentals/.
如果我想以原子方式将数据保存在两个集合(A 和 B)中,那么我不能使用 MongoDB 来做到这一点,即如果在 B 的情况下保存失败,A 仍然会有数据.这不是一个很大的缺点吗?
If I want to save data in two collections(A and B) atomically, then i can't do that using MongoDB i.e. if save fails in case of B, still A will have the data. Isn't it a big disadvantage?
不过,人们仍在使用 MongoDB 而不是 RDBMS.为什么?
Still, people are using MongoDB rather than RDBMS. Why?
推荐答案
MongoDB 4.0 现在增加了对多文档 ACID 事务的支持.以供参考参见参考
MongoDB 4.0 adds support for multi-document ACID transactions now.For referenceSee Refrence
这篇关于MongoDB 中的事务支持的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!