Computer Basics - Database

What is a Database?

  • A database stores data in a structured way so that computers can quickly find, insert, update, or delete information.

  • Instead of keeping information in random files, databases organize data systematically (like tables, rows, and columns).


Key Features of a Database

  1. Organized structure – Data is stored in a systematic way (like rows and columns in a table).

  2. Efficient data access – Makes it easy to search and retrieve specific data.

  3. Data integrity – Ensures accuracy and consistency of data.

  4. Security – Access can be restricted with passwords, roles, and permissions.

  5. Multi-user support – Many users can access the database at the same time.

  6. Backup and recovery – Databases can restore lost data in case of failure.

  7. Scalability – Can handle small amounts of data (like a school record) to massive amounts (like Google search index).


Types of Databases

  1. Relational Database (RDBMS) – Stores data in tables (rows and columns).

    • Example: MySQL, Oracle, PostgreSQL.

  2. NoSQL Database – Stores unstructured or semi-structured data (JSON, documents, key-value pairs).

    • Example: MongoDB, Cassandra.

  3. Distributed Database – Data is spread across multiple locations/servers.

  4. Cloud Database – Hosted and managed in the cloud (Google Firebase, Amazon RDS).


Examples of Databases in Real Life

  • Banking system → Stores customer accounts and transactions.

  • Library system → Manages books and borrowers.

  • E-commerce sites → Store product details, customer data, and orders.

  • Social media → Store user profiles, posts, and messages.