0% found this document useful (0 votes)
3 views

Database_Unit_Notes

Lecture notes on database - introduction to database systems

Uploaded by

spartawizzo779
Copyright
© © All Rights Reserved
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
3 views

Database_Unit_Notes

Lecture notes on database - introduction to database systems

Uploaded by

spartawizzo779
Copyright
© © All Rights Reserved
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 3

Database Unit Notes

1. Introduction to Databases
- Definition: A database is an organized collection of data.
- Examples: Banking systems, e-commerce websites.
- DBMS: Software to manage databases (e.g., MySQL, Oracle).

2. Types of Databases
1. Relational Databases:
- Data is stored in tables (rows and columns).
- Example: MySQL, PostgreSQL.

2. NoSQL Databases:
- For unstructured data (e.g., MongoDB, Cassandra).

3. Distributed Databases:
- Data stored across multiple servers (e.g., Apache Cassandra).

4. Cloud Databases:
- Hosted on platforms like AWS and Google Cloud.

3. Database Architecture
- Single-Tier: Database and application on one machine.
- Two-Tier: Client and server interact directly.
- Three-Tier: Layers for presentation, logic, and database.

4. Components of a DBMS
- Database Engine: Handles storage, retrieval, and updates.
- Query Processor: Converts SQL to machine instructions.
- Transaction Management: Ensures consistency in operations.
- Metadata: Data about data (e.g., table names, data types).

5. Database Design
- Conceptual Design: Use Entity-Relationship Diagrams (ERDs).
- Logical Design: Convert ERDs to tables, follow normalization.
- Physical Design: Implement tables, indexes in the DBMS.

6. Keys in Databases
- Primary Key: Unique identifier for table records.
- Foreign Key: Links two tables via a primary key.
- Composite Key: Combines multiple columns for unique identification.
7. SQL (Structured Query Language)
- DDL: CREATE, ALTER, DROP tables.
- DML: INSERT, UPDATE, DELETE records.
- DQL: SELECT data.
- DCL: GRANT and REVOKE permissions.

8. Normalization
- 1NF: Eliminate duplicate columns, ensure atomic data.
- 2NF: Non-key attributes depend on the entire primary key.
- 3NF: Eliminate transitive dependencies.

9. Transactions
- Properties (ACID):
- Atomicity: All operations succeed or none do.
- Consistency: Maintains database validity.
- Isolation: Transactions don't interfere with each other.
- Durability: Changes persist after system failures.

10. Indexing
- Speeds up data retrieval.
- Clustered Index: Sorts data physically.
- Non-Clustered Index: Creates logical order without altering physical order.

11. Database Security


- Authentication: Verify user identity.
- Authorization: Control user actions.
- Encryption: Secure data in storage and transmission.
- Backup: Regular data copies for recovery.

12. Backup and Recovery


- Full Backup: Copies the entire database.
- Incremental Backup: Copies only changes since the last backup.
- Recovery Types: Point-in-time recovery, cold recovery, hot recovery.

13. Advantages of Databases


- Data Integrity: Ensures accuracy and consistency.
- Data Security: Protects sensitive information.
- Scalability: Handles large data volumes.

14. Challenges in Database Systems


- Cost: Expensive hardware, software, and staffing.
- Complexity: Requires expertise to design and maintain.
- Security Risks: Vulnerable to breaches without proper safeguards.
15. Emerging Trends in Databases
- Big Data Technologies: Tools like Hadoop for large-scale data.
- Cloud Databases: Scalable and accessible online storage.
- AI-Driven Databases: Automated performance optimization.
- Blockchain Databases: Decentralized and secure data storage.

You might also like