Chapter 1: Introduction Flashcards
What is a Database
A massive software
When asked, “What is better, X or Y?” what should your answer be
It depends because of how massive DB is
What is OLTP
Online Transaction Processing
What does OLTP do
tracks transaction changes in a system. this involves lots of writing to the system, causing many changes to the DB
What does OLTP try to minimize
OLTP tries to minimize the number of writes done because writing to the system takes a lot of time.
What is OLAP
Online Analytic Processing
What does OLAP do
OLAP reads and analyzes from the DB. It is read oriented and makes very few changes to the DB.
What is the purpose of Schema?
Schema make up the logical structure of the DB. They structure the DB and determine how the data is stored, just like what classes do in programs.
What is the purpose of Instances?
Instances are the actual contents of the DB at a particular point in time. They are analogous to variables in programs.
What is a Data Model?
Data models describe data, data relationships, data semantics, and data constraints (rules). They range from laymen to technical and human oriented to machine oriented. All data models are functionally equivalent to each other.
What types of Data Models are there?
- Entity-Relationship data model (for laymen and database design)
- Relational model (mathematical)
- Relational DB (technical)
What are the languages for the Data Models?
- ER (Entity Relationship Model) Language: GUI, Diagrams
- Relational model: Relational Algebra (procedural language)
- RDB Language: SQL (Declarative language)
What is a DML?
Data Manipulation Language. A language for accessing and manipulating the data organized by the appropriate data model (aka query language)
What classes of DML languages are there?
- Procedural: user specifies what data is required and how to get that data (I want x so go here and …)
- Declarative: user specifies what data is required without specifying how to get it (I want this)
What is a DDL?
Data definition language.
- notation for defining database schema
- comprised of database schema, integrity constraints, and authorization
What is the differences between DDLs and DMLs?
- DDL: operates on schema and the structure of the DB (like types in a program)
- DML: operates on the contents/instances (like variables)
What is the difference between declarative languages and procedural languages?
declarative languages you declare WHAT you want, and procedural languages you describe HOW to get what you want
In an Entity-Relationship model what are the terms for a “thing”, “a set of things”, and “essential characteristics”?
- “thing” = entity
- “a set of things” = entity set (or relationship set)
- “essential characteristics” = attributes
In an Relational model what are the terms for a “thing”, “a set of things”, and “essential characteristics”?
- “thing” = tuple
- “a set of things” = relation
- “essential characteristics” = attributes
In an Relational Database model what are the terms for a “thing”, “a set of things”, and “essential characteristics”?
- “thing” = row
- “a set of things” = table
- “essential characteristics” = columns
What is a Relational Database?
A databse based on the relational data model. Is represented by a collection of tables and includes DML and DDL.
What makes Relational Databases such powerful tools?
- simple representations of data (everything is a table)
- separates the WHAT (SQL) from the HOW (relational algebra)