- Query all information
select * from table name; - Query the corresponding column
select column name to be viewed 1, column name to be viewed 2 ... from table name; - Take alias
select column name to view 1 [as] alias, column name to view 2 [as] alias… from table name; - Filter duplicate data
select distinct column name from table name; (column name is the name of the filtered column) - The selection
column is an expression: Select column name (number type column) * 0.8 from table name;
Ceil (value): round up example: ceil (321.1) = 322
Floor (value): round down example: floor ( 321.9) = 321
Round (value): round to five rounds Example: Round (321.1) = 321 Round (321.9) = 322 - Query condition
Select * from table name where condition - Relational operator
<> = <=! = (<>) Is not equal to =
- Logical operator
And (both)
Or (or)
Not (negated)
isNull (is empty)