2.2.3 SQL Flashcards
1
Q
List the three SQL commands we need [3]
A
SELECT [1] FROM [1] WHERE [1]
2
Q
What symbol means ‘All’ in SQL? [1]
A
*
3
Q
What is the command to see all fields from the table ‘users’?
A
SELECT * from users
4
Q
What is the command to select the firstname and secondname fields from customers where the first name is ‘Dave’?
A
SELECT firstname, secondname FROM customers WHERE firstname = ‘Dave’
5
Q
What is the command to select the username from users where age is greater than 13?
A
SELECT username FROM users WHERE age > 13