课程: Databases for Node.js Developers (2021)
今天就学习课程吧!
今天就开通帐号,24,700 门业界名师课程任您挑!
When to use relational databases
- [Instructor] We covered the pros and cons of document databases versus relational databases already when we talked about document databases before. But let me emphasize that again real quick. You want to use relational databases when there are multiple different entities that are in some way related and when the database needs to stay in a consistent state, and when the database should also enforce this consistency no matter from which application it is accessed. In our example later in this chapter, we will use my sequel to store our orders. For that we will first transition the basket that is currently stored into an order, and we will store all items inside this order in a table order item. Then we will delete the contents of the basket and everything going on here should run in one transection. This means it's either everything or nothing and that's a very nice use case for relational database like my sequel.
内容
-
-
-
-
-
-
-
(已锁定)
When to use relational databases59 秒
-
(已锁定)
Set up MySQL3 分钟 20 秒
-
(已锁定)
Create a database schema4 分钟 17 秒
-
(已锁定)
Use Node.js with MySQL9 分钟 58 秒
-
(已锁定)
Introduction to Sequelize2 分钟 4 秒
-
(已锁定)
Add MySQL and Sequelize to your project6 分钟 28 秒
-
(已锁定)
Review the database design2 分钟
-
(已锁定)
Create sequelize models8 分钟 51 秒
-
(已锁定)
Review the auto-generated database structure2 分钟 20 秒
-
(已锁定)
Implement an order service8 分钟 29 秒
-
(已锁定)
Add order management7 分钟 13 秒
-
(已锁定)
-