Meaning
A Database Management System (DBMS) is software that interacts with end-users, applications, and the database itself to capture and analyze data. It allows for data to be stored, modified, and extracted efficiently and securely.
Advantages of Using a DBMS
Data Integrity: Ensures data accuracy and consistency.
Data Security: Restricts unauthorized access.
Data Administration: Simplifies data management tasks.
Concurrent Access: Allows multiple users to access data simultaneously without conflicts.
Data Independence: Changes in data structure do not affect the application programs.
Backup and Recovery: Facilitates automatic data backup and recovery processes.
1. Hierarchical DBMS
Structure: Data is organized in a tree-like structure.
Advantages: Simple and fast for hierarchical data relationships.
Disadvantages: Rigidity; difficult to manage non-hierarchical relationships.
2. Network DBMS
Structure: Data is organized as a graph with many-to-many relationships.
Advantages: Flexible and can handle complex relationships.
Disadvantages: More complex to design and manage.
3. Relational DBMS (RDBMS)
Structure: Data is organized in tables (relations).
Advantages: Simple and powerful query capabilities using SQL; widely used.
Disadvantages: Can be less efficient for certain types of data and queries.
4. Object-Oriented DBMS (OODBMS)
Structure: Data is stored as objects, similar to object-oriented programming.
Advantages: Can handle complex data and relationships; supports inheritance and polymorphism.
Disadvantages: Less mature and less widely adopted than RDBMS.
5. Object-Relational DBMS (ORDBMS)
Structure: Combines features of both relational and object-oriented databases.
Advantages: Supports complex data types and relationships while maintaining relational capabilities.
Disadvantages: Can be more complex to implement and manage.
Data Models
Definition: Abstract representations of the data, the relationships between data, and the constraints on the data.
Types:
Hierarchical Model
Network Model
Relational Model
Object-Oriented Model
Schemas and Instances
Schema: The overall structure of the database (blueprint).
Instance: The actual data stored in the database at a particular moment in time.
Three Schema Architecture
Internal Schema: Describes the physical storage structure of the database.
Conceptual Schema: Describes the logical structure of the entire database.
External Schema: Describes the part of the database that a particular user group is interested in.
Data Independence
Logical Data Independence: Ability to change the conceptual schema without changing the external schema.
Physical Data Independence: Ability to change the internal schema without changing the conceptual schema.
Domain Constraints: Restrictions on the values that can be stored in a column.
Key Constraints: Ensures that each row in a table is unique (e.g., primary keys).
Entity Integrity Constraints: Ensures that no primary key can have a null value.
Referential Integrity Constraints: Ensures that a foreign key value always points to an existing row in another table.