1. General
Database
Collection of permanently and digitally stored data.
Database model
A collection of rules to describe the possible structure consistency rules and behaviour of a
database.
Database Management System (DBMS)
A system that manages multiple databases and allows multiple applications to access data at
the same time.
NoSQL database
● Column-oriented database: data is stored in columns.
● Document-oriented database: data is stored in documents following some standard (i.e.
JSON, XML, etc.).
● Key-value database: data is stored in dictionaries or hash tables.
● Graph database: data is stored in nodes and edges (connections).
Types of data
● Structured data: tabular data (row & columns) in a strict format.
● Unstructured data: raw data (i.e. text files).
Relation
Table with rows and columns.
Attribute
Named columns of relation.
Value range
Set of valid values for one or more attributes.
Tuple
Row of a relation.
Super key
Attribute or a set of attributes used to uniquely identify tuples in a relation.
● Key candidate: minimal required attributes to maintain unique identification.
Primary key
The key candidate selected to uniquely identify tuples of a relation.
1
, Foreign key
Attribute which corresponds with the primary key of another relation.
Relation schema
Schema composed of the relation name, attributes and the primary key.
Relation database
Collection of normalized relations.
Integrity types
● Attribute integrity: Constraints based on an attribute i.e. limiting attribute values to a
specified range.
● Static tuple integrity: Limit the possible combination for values in a tuple.
● Static relation integrity: Constraints based on a relation ie.e the simultaneous occurrence
of certain tuples in a relation.
● Static database integrity: Constraints based on a database i.e. the primary key of relation
must exist if a foreign key references this attribute.
● Referential Integrity
● Restricted: reject update/delete action.
● Cascade: propagate into child relation on update/delete action.
● Nullify: set corresponding value to NULL on update/delete action.
Integrity conditions
● Static Integrity Condition: Limit the database status i.e. name must always be entered
(can be created with regular constraints).
● Dynamic Integrity Condition: Limit status changes or their consequences (can be created
with trigger constraints) i.e. single → married → {divorced, widowed}.
SQL types
● DDL: data definition language, defines database structure & schema.
● DML: data modification language, manages data within schema objects.
● DCL: data control language, manages data access, authentication & authorization.
● TCL: transaction control language, manages transactions within the DML language.
Transaction
Consists of one or more statements that are executed by one database client and select, insert,
update or delete data in the database.
2
The benefits of buying summaries with Stuvia:
Guaranteed quality through customer reviews
Stuvia customers have reviewed more than 700,000 summaries. This how you know that you are buying the best documents.
Quick and easy check-out
You can quickly pay through credit card or Stuvia-credit for the summaries. There is no membership needed.
Focus on what matters
Your fellow students write the study notes themselves, which is why the documents are always reliable and up-to-date. This ensures you quickly get to the core!
Frequently asked questions
What do I get when I buy this document?
You get a PDF, available immediately after your purchase. The purchased document is accessible anytime, anywhere and indefinitely through your profile.
Satisfaction guarantee: how does it work?
Our satisfaction guarantee ensures that you always find a study document that suits you well. You fill out a form, and our customer service team takes care of the rest.
Who am I buying these notes from?
Stuvia is a marketplace, so you are not buying this document from us, but from seller tomdewildt. Stuvia facilitates payment to the seller.
Will I be stuck with a subscription?
No, you only buy these notes for $5.89. You're not tied to anything after your purchase.