강의 자료
Database
A collection of data
- DBMS: Database Management System
- DBMS types:
- 계층형 DMBS (Hierarchical DBMS)
- 망형 DBMS (Cloud DBMS)
- 관계형 DBMS (Relationnal DBMS): Called RDBMS. Most DBMS use the RDBMS type
DBMS examples
SQL (Structured Query Language) vs. NoSQL
SQL (Relational)
Products: MySQL, Oracle, etc.
Better for jobs with a lot of edits and deletions.
- Pros:
- Clear schema
- Guarantees data integrity
- Saves one data without duplicates
- Cons:
- Less flexible. The data schema must be planned beforehand that may be difficult to change later on
- Is relational and can lead to complicated join queries
- Can usually only be expanded vertically
NoSQL (Non-relational)
Product: MongoDB, etc.
Saves data in various ways. Is schema-less meaning there is no structure or relationship.
Better for jobs that require to read the data a lot.
- Pros:
- Is schema-less and flexible. Can edit or add data any time.
- Saves data in a form required by the app that can read data faster.
- Can be expanded vertically and horizontally
- Cons:
- Can lead to forming a schema later due to its flexibility
- Duplicate data must be continually updated
- Data can be saved in duplicate in several collections and they must all be edited to edit a field
Designing a database