relational databases and SQL Flashcards
define a database
a collection of data organised in a way for computer programs to easily search and store data
define a relational database
multiple tables linked together
what is a primary key?
a unique identifier for a record
what is a foreign key?
what does relational databases do?
- reduce data inconsistency
- reduce data redundancy
what statements are needed to retrieve data from a relational database?
SELECT
FROM
WHERE
ORDER BY .. ASC / DESC
what statements are needed to insert data into a relational database?
INSERT INTO tablename
VALUES
what statements are needed to edit data into a relational database?
UPDATE tablename
SET
WHERE condition
what statements are needed to delete data from a relational database?
DELETE FROM tablename
WHERE condition