Skip to main content
Reserved words have special meanings to the Firebolt SQL engine. We recommend that you do not use these words for naming databases, tables, columns, variables, or other objects that you define. If you must use a reserved word in this way, enclose it in quotation marks.

Column aliases are the exception

Naming a database, table or column after a reserved word needs quoting, as above. A column alias is more forgiving, because there is nothing for the word to be confused with in that position. These are all accepted unquoted: BOTH, FIRST, FULL, LEADING, NATURAL, OUTER, TRAILING, USING Which reads oddly and is nonetheless valid — even the join keywords are fine here, because a select list has nothing to join:
TOP, TRUE and FALSE work as an alias too, but only after AS. Written bare they are still read as the row-limit clause and as boolean literals:
ROWS needs quoting in either position, because it opens a window frame:
  • ALL
  • ALTER
  • AND
  • ARRAY
  • BETWEEN
  • BIGINT
  • BOOL
  • BOOLEAN
  • BOTH
  • CALL
  • CASE
  • CAST
  • CHAR
  • CONCAT
  • COPY
  • CREATE
  • CROSS
  • CURRENT_DATE
  • CURRENT_TIMESTAMP
  • DATABASE
  • DATE
  • DATETIME
  • DECIMAL
  • DELETE
  • DESCRIBE
  • DISTINCT
  • DOUBLE
  • DOUBLECOLON
  • DOW
  • DOY
  • DROP
  • EMPTY_IDENTIFIER
  • ENGINE
  • EPOCH
  • EXCEPT
  • EXECUTE
  • EXISTS
  • EXPLAIN
  • EXTRACT
  • FALSE
  • FETCH
  • FIRST
  • FLOAT
  • FROM
  • FULL
  • GENERATE
  • GROUP
  • HAVING
  • IF
  • ILIKE
  • IN
  • INNER
  • INSERT
  • INT
  • INTEGER
  • INTERSECT
  • INTERVAL
  • IS
  • ISNULL
  • JOIN
  • JOIN_TYPE
  • LATERAL
  • LEADING
  • LEFT
  • LIKE
  • LIMIT
  • LIMIT_DISTINCT
  • LOCALTIMESTAMP
  • LONG
  • NATURAL
  • NEXT
  • NOT
  • NULL
  • NUMERIC
  • OFFSET
  • ON
  • ONLY
  • OR
  • ORDER
  • OUTER
  • OVER
  • PARTITION
  • PRECISION
  • PREPARE
  • PRIMARY
  • QUARTER
  • RIGHT
  • ROW
  • ROWS
  • SAMPLE
  • SELECT
  • SET
  • SHOW
  • SYSTEM
  • TEXT
  • TIME
  • TIMESTAMP
  • TOP
  • TRAILING
  • TRIM
  • TRUE
  • TRUNCATE
  • UNION
  • UNKNOWN_CHAR
  • UNNEST
  • UNTERMINATED_STRING
  • UPDATE
  • USING
  • VARCHAR
  • WEEK
  • WHEN
  • WHERE
  • WITH