Voc Flashcards
Why do we need a DB
Avoid redundancy
data integrity
referential integrity
deletion anomalies
data integrity
refers to the validity of data
avoid redundacy
avoid duplication of information in multiple table within the DB
deletion Anomalies
deletion of one of a table results in the deletion of unintended information
Referential integrity
ensures that relationships between table remain consistent.
cant add a record to the table that contains the foreign key unless there is a corresponding record in the linked table.
redundacy
duplication of information in multiple tables
insertion anomoly
user is unable to insert a new record when it should be possible to do so
deletion anomoly
record is deleted other information tied to the is also deleted
update anomoly
record is updated but other appearances of the same item is not updated.
unified modeling language
used to describe conceptual view of the database
relational model
formal model of the database
relational algebra
a formal language used to symoblically manipulate objects of the relational model
tabel model
informal set of terms for relational model objects. terms used to refer to the physical view of the database
structured query language
is used to build and manipulate relational databases. based on relational algebra. its is declarative. stadard but some products very on implementatin.
uml class or entity
anything in that is to be represented in the db
first step of building a db
model it in natural language
attribute
is a piece of inofrmation that characterizes each member of a class
descriptive atttributes/ natural attributes
those which actually provide real world information about the class. id numbers are not descriptive
class diagram
shows the class and its attributes
relational scheme
starts with the attributes from the class diagram.
sets
domain of all the attributes that belong to a class.
Create table nameTable()
creates a table; CREATE TABLE customers ( cfirstname VARCHAR(20) NOT NULL, clastname VARCHAR(20) NOT NULL, cphone VARCHAR(20) NOT NULL, cstreet VARCHAR(50), czipcode VARCHAR(5));
data models
conceptual, logical, physical
rows
each instance of the class is represented by a row.