A relational database is a digital database based on the relational model of data. In simple words, it is a collection of data items with pre-defined relationships between them. These items are organized as a set of tables, with columns and rows. Each column stores some specific attribute of an object/entity and the row represents a specific object/entity.
A software system used to maintain relational databases is a relational database management system (RDBMS), for e.g., MySQL, Oracle DB, PostgreSQL, etc. Virtually all relational database systems use SQL (Structured Query Language) for querying and maintaining the database.
-
Primary Key
-
Candidate Key
-
Composite Key
-
Prime/Non-prime attribute
- DDL
- DML
- DCL
- TCL
| Type | Command List |
|---|---|
| DDL | CREATE |
| DROP | |
| ALTER | |
| RENAME | |
| TRUNCATE | |
| DML | SELECT |
| INSERT | |
| UPDATE | |
| DELETE | |
| DCL | GRANT |
| REVOKE | |
| TCL | START TRANSACTION |
| COMMIT | |
| ROLLBACK |
- Inner Join
- Left Outer Join
- Right Outer Join
- Full Join
- Self Join
- 1NF
- 2NF
- 3NF
- BCNF
- 4NF
- 5NF
Required conditions:
a. All values should be atomic (non-breakable).
b. There should be a candidate key or a composite key (basically you should be able to uniquely identify all records in the table).