Introduction to Databases Definition of a database Importance of databases in modern society Different types of databases (flat file, relational, object-oriented)
Types of Databases Flat file databases Consist of a single table with all the data Simplest form of database, used for small amounts of data Relational databases Organize data into multiple tables with relationships Most commonly used type of database Object-oriented databases Store data as objects with attributes and behaviors Commonly used in complex applications, such as multimedia systems
Components of a Database System Data Raw facts and figures that are being stored and managed Examples: names, addresses, grades Tables Organized collections of data with a specific structure Represented as rows and columns Fields Smallest units of data, represented as columns in a table Examples: first name, last name, age Records Complete set of fields in a table, represented as rows Examples: information about a specific customer, student
Database Design and Normalization Database design Process of creating a structure for storing and organizing data in a database Involves defining tables, fields, relationships, and constraints Normalization Method for minimizing data redundancy and improving efficiency Removes data duplication and ensures data integrity
Entity-Relationship (ER) Modeling ER modeling Technique for visualizing and designing a database Uses entities, attributes, and relationships to represent the structure of data Entities Objects, concepts, or things that need to be stored in the database Examples: customers, products, employees Attributes Characteristics or properties of entities Examples: name, age, gender Relationships Connections between entities Examples: customer buys product, employee manages project
Database Management Systems (DBMS) DBMS Software that allows users to create, access, and manage databases Provides tools and features for data organization, storage, retrieval, and manipulation Common DBMS examples Oracle, MySQL, Microsoft SQL Server Each DBMS has its own features, strengths, and limitations