SQL Flashcards
1
Q
What SQL datatypes could be used for a fractional number?
A
FLOAT
REAL
2
Q
What SQL datatypes can be used for dates and time
A
DATE
TIME
DATETIME
3
Q
What is one way of defining a customer ID (int) value?
A
CustomerID INT PRIMARY KEY
4
Q
What are the main clauses of a select query?
A
SELECT
FROM
WHERE
5
Q
What symbol denotes all fields in a table?
A
*
6
Q
What clause orders items?
A
ORDER BY
7
Q
Write a query to select all fields from a sales table where value is more than £500
A
SELECT * FROM SALES WHERE Value > 500;
8
Q
What is the format to add values into a SQL table
A
INSERT INTO VALUES ;
9
Q
What are the main clauses of an update query?
A
UPDATE
SET
WHERE