MongoDB或PostGreSQL,哪一个与Python Django、Express和Node js更优?

2024-06-16 14:02:00 发布

您现在位置:Python中文网/ 问答频道 /正文

因为我处理的是像从一个帐户借记和另一个帐户贷记这样的钱,所以对于这项工作,我认为我的数据库必须严格遵循所有ACID属性,因此对于这项工作来说,它将更加兼容MongoDB或Postgresql,因为我已经读到MongoDB不遵循ACID属性,这就是为什么我感到困惑。


Tags: 数据库属性postgresqlmongodb帐户借记acid贷记
1条回答
网友
1楼 · 发布于 2024-06-16 14:02:00

SQL RDBMS绝对是您的选择。如果您在Mongo和PostgreSQL之间进行选择,那么PostgreSQL将是答案。在

如蒙哥官方常见问题解答所述:

MongoDB may not be a good fit for some applications. For example, applications that require complex transactions (e.g., a double-entry bookkeeping system) and scan-oriented applications that access large subsets of the data most of the time may not be a good fit for MongoDB. MongoDB is not a drop-in replacement for legacy applications built around the relational data model and SQL.

相关问题 更多 >