The Relational Model Flashcards
describe a relational model
represents the database as a collection of relations
what is a relation
a table of values
row= related data values
column= attribute
what is a tuple
a single record- a row
what is a relation schema
name of a relation with attributes
what is the degree of a relation
the number of attributes
what is the cardinality of a relation
the number of rows
what is a relation instance
a set of tuples related only to the key of the relation
what is the attribute domain
the predefined value and scope of an attribute
what is a relational integrity constraint
a condition that must be present for a valid relation
what are the three categories of integrity constraint
domain
key
referential integrity
what are the four main operations performed on a relational model
insert
delete
modify
select
what are the possible violations by insert
all three
key- if the key value already exists
domain- if the tuple breaks the domain
referential integrity- if the FK isn’t valid
what are the possible violations by update
domain
unless modifying a P or F K
what are the possible violations by delete
what can you do to fix it
referential integrity
restrict- don’t allow it
cascade- delete all references
set null- set FKs to null
what are the advantages of a relational model (6)
simplicity
structural independence
ease of use
queries
data independence
scalable