CH2 Flashcards
What is data abstraction ?
it is hiding details that are not useful
what is a data model?
it is a collection of concepts used to describe the structure of a database
DATA MODEL provides the requirement for data abstraction + basic operation for retrieval and update
and specify the behavior of the database application
what does the data model provide?
1) req for data abstraction
2) basic operations for data retrieval and update
3)specify the behavior of the database application
4) User-defined operations
categories of data models:
1) high-level or conceptual simple models provide data similar to how users understand it. ex: ER-mode
(used by typical end users)
2) low level or physical: describes details about how data is stored
(used by computer specialists)
3)representational: between conceptual and physical, not too hard to understand by most users and not hard to implement
-relational -hierarchical -network
what is a database schema
Schema: Defines the structure of data within a specific database.
what is a database state?
A database state refers to the data stored in the database at a specific point in time
what is the difference between initial state and the current state?
the initial state is how the database looks when it’s first set up, while the current state is the database as it is right now, after all the modifications.
catalog vs schema
Catalog:
Think of it as a high-level container or directory that holds multiple schemas.
It provides an overview of the entire database system and contains information about all the schemas and their associated objects (like tables, indexes, etc.).
A catalog helps manage and organize multiple schemas within a single database system.
Schema:
A schema is a specific organizational unit within a catalog.
It defines the structure of data, including tables, fields, and relationships between them.
Schemas are used to group related database objects and manage their organization and access.
what is the goal of the 3 schema architecture
separates the user application and the physical database to provide:
program data independence
support multiple views
what are the 3 levels of schema:
internal level (describes the physical storage )
conceptual(describes entities data type and relationships)
external/ view level(user views designed for particular users)
what is data independence?
Data independence refers to the ability to change the schema at one level without affecting other levels.
what are the two types of data independence?
logical and physical
logical = change conceptual - no change external
Physical change internal - no change in conceptual
what is DDL SDL DML?
DDL (Data Definition Language): Defines and manages database structure (e.g., CREATE, ALTER, DROP).
SDL (Storage Definition Language): Specifies how data is physically stored (handled internally by the system).
DML (Data Manipulation Language): Manages and retrieves data (e.g., INSERT, UPDATE, DELETE, SELECT).