Fundamentals of Databases Flashcards

You may prefer our related Brainscape-certified flashcards:
1
Q

Relational Database

A

A method of creating a database using tables of related data, with relationships between the tables.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

Entity

A

An object about which data will be stored

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

Entity Relationship Diagram

A

http://www.teach-ict.com/as_a2_ict_new/ocr/AS_G061/315_database_concepts/attributes_entities/miniweb/images/one2many.jpg
One to many

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

Primary Key

A

An attribute that can be used to uniquely identify every record within a table

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

Entity Identifier

A

An attribute which can uniquely identify each instance of an entity

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

Foreign Key

A

An attribute in a table that is a primary key in another table and is used to link tables together.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

Normalisation

A

The process of ensuring that a relational database is structured efficiently.
This is by removing repeating/redundant data. For example, a school database - tutor group may repeat a lot. One way to solve this is to put tutor table as a separate database.

Pg 369

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

SQL

A

Enter data into a table
INSERT INTO Customer (CustomerID, Name, Address)
VALUES (“1”, “John Smith”, “1 High Street”)

This means insert CustomerID = 1, Name = John Smith, and Address = 1 High Street into database Customer.

Update data in the table

UPDATE Customer
SET Address = “29 Wellington Street”
WHERE CustomerID = “1”

Delete Data

DELETE * FROM CUSTOMER
* means all

Querying Data

SELECT CustomerName, CustomerAddress
FROM Customer
WHERE CustomerName = “John Smith”
ORDER BY CustomerName DESC;

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

Issues with concurrent (multiple) access on shared database

A

One common problem with a database that is accessible to a number of users is what to do if a number of users are trying to access the same data at the same time. As long as the users are only reading the data this is not a problem, but if two or more users want to write data there will be problems.

How to solve?
- Record Locks - a technique to temporarily prevent access to certain records held on a database

  • Serialisation - A technique to ensure that only one transaction at a time is executed from at a time is executed from multiple users on a database.

Timestamp ordering - A technique to ensure multiple users can execute commands on a shared database based on the timestamp of when the data was last written to or read from.

Commitment ordering - A technique to ensure concurrent transactions on a shared database are executed based on the timestamp of when the request is made and also the precedence the request takes over other simultaneous request.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

Big Data

A

A generic term for large or complex datasets that are difficult to store and analyse.

Main three big features of big data are:
Volume
Variety
Velocity

Examples include:
Scientific research, retail, banking, government, mobile networks, security, the internet.

Structured data - data that fit into a standard database structure or columns and rows.

Unstructured data - data that do not fit into a standard database structure of columns and rows.

Modelling big data - most big datasets are stored in what are called data warehouses, which as the name suggests, are very large. Modelling of big data can be expressed as diagrams or natural language such as We sold 1 million rechargeable batteries. Using We sold QUANTITY PRODUCTS format, it is possible to model other data that the retailer records.

Read rest pg 386

How well did you know this?
1
Not at all
2
3
4
5
Perfectly