T7 - SQL Flashcards
1
Q
SQL
A
stands for Structured Query Language
allows you to create, query and add data to databases
2
Q
SELECT
A
… (list the fields to be displayed)
3
Q
FROM …
A
(specify the table name)
4
Q
WHERE
A
… (list the search criteria)
5
Q
“wild card”
A
- to mean “all columns”
6
Q
WHERE clause
A
is used to select only records satisfying a specified condition:
7
Q
Operators in where clause:
A
= != > < >= <= AND, OR, NOT
8
Q
BETWEEN
A
between an inclusive range
9
Q
LIKE
A
search for a pattern
10
Q
Sorting:
A
ORDER BY allows a query to sort data by ascending or descending order
11
Q
To sort by ascending order:
A
ORDER BY Surname ASC
12
Q
To sort by descending order:
A
ORDER BY Surname DESC