Relational databases/SQL Flashcards

1
Q

Explain the concept of a database and the different types

A

A collection of data as tables where they are held together in an organised or logical way

Each complete data entity within a database is called a record (each row) and it is split into certain data categories, these are called the fields (each column) of the record.

The primary key of a database table is a specific column(s) designated to uniquely identify each record. The primary key is copied into other tables as the foreign key

The foreign key is a column(s) used in a relational database to link data between tables and they contain the primary key of a related table

A flat-file database is a database with only one table

A relational database organises data into 2 or more tables which can be linked to one another

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

Why is a database a better storage techniques than file systems?

A

Data duplication is avoided in databases
Data is also consistent in databases

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

How does a database prevent data duplication

A

By using a unique primary key field for each record

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

List a few applications of databases

A

Online shopping lists
Security systems
Social networking sites

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

What is the function of a query language and explain an example

A

-used to customise and retrieve information from the database
-e.g. Structured Query Language (SQL)

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