SQL

Statements

A SQL statement can include one or more of the following parts:

  • Clause, such as FROM
  • Command, such as SELECT
  • Expression, a combination of one or more values, operators, and SQL functions that evaluate a value. For example, users.firstname is a period expression.
  • Function, scalar, and aggregate, such as sum
  • Literal value
    • Boolean
    • Identifier
    • Integer
    • Numeric constant
    • String
  • Operator, such as NOT IN, LIKE, and AND
  • Predicate, such as a > b in SELECT * FROM myfile WHERE a > b.
  • Whitespace
  • Comment in the following format:
      /* This is a comment. */