Databases & SQL (paper 2) Flashcards
what is a database
a way of holding data in an organised way so that searching for data items meeting certain criteria is quick and easy
What is the order of tables fields and records inside a database
Tables are inside a database
There are field (columns) in a table
Records are rows in a database
what is A on this diagram
the unique ID
whats is B on this diagram
the table
what is C on this diagram
a field
what is B on this diagram
a record
what does SQL stand for
structures query language
what is used to search records in a database
SQL
What is the structure of SQL code
SELECT … , … , …
FROM (table name)
WHERE (condition)
ORDER BY (field name) ASC / DESC;
what is the code used to count the number of records with a condition
SELECT COUNT(…)
FROM (table name)
WHERE …;
whats is the code used to find the total of all records in a field
SELECT SUM(…)
FROM (table name)
WHERE …;
What is a unique Id
A unique identifier which is different for each record of a table