Appendix C: Reserved Words and Keywords

Reserved words are part of the Firebird SQL language. They cannot be used as identifiers (e.g. as table or procedure names), except when enclosed in double quotes in Dialect 3. However, you should avoid this unless you have a compelling reason.

Keywords are also part of the language. They have a special meaning when used in the proper context, but they are not reserved for Firebird’s own and exclusive use. You can use them as identifiers without double-quoting.

Reserved words

Full list of reserved words in Firebird 2.5:

ADD

ADMIN

ALL

ALTER

AND

ANY

AS

AT

AVG

BEGIN

BETWEEN

BIGINT

BIT_LENGTH

BLOB

BOTH

BY

CASE

CAST

CHAR

CHAR_LENGTH

CHARACTER

CHARACTER_LENGTH

CHECK

CLOSE

COLLATE

COLUMN

COMMIT

CONNECT

CONSTRAINT

COUNT

CREATE

CROSS

CURRENT

CURRENT_CONNECTION

CURRENT_DATE

CURRENT_ROLE

CURRENT_TIME

CURRENT_TIMESTAMP

CURRENT_TRANSACTION

CURRENT_USER

CURSOR

DATE

DAY

DEC

DECIMAL

DECLARE

DEFAULT

DELETE

DELETING

DISCONNECT

DISTINCT

DOUBLE

DROP

ELSE

END

ESCAPE

EXECUTE

EXISTS

EXTERNAL

EXTRACT

FETCH

FILTER

FLOAT

FOR

FOREIGN

FROM

FULL

FUNCTION

GDSCODE

GLOBAL

GRANT

GROUP

HAVING

HOUR

IN

INDEX

INNER

INSENSITIVE

INSERT

INSERTING

INT

INTEGER

INTO

IS

JOIN

LEADING

LEFT

LIKE

LONG

LOWER

MAX

MAXIMUM_SEGMENT

MERGE

MIN

MINUTE

MONTH

NATIONAL

NATURAL

NCHAR

NO

NOT

NULL

NUMERIC

OCTET_LENGTH

OF

ON

ONLY

OPEN

OR

ORDER

OUTER

PARAMETER

PLAN

POSITION

POST_EVENT

PRECISION

PRIMARY

PROCEDURE

RDB$DB_KEY

REAL

RECORD_VERSION

RECREATE

RECURSIVE

REFERENCES

RELEASE

RETURNING_VALUES

RETURNS

REVOKE

RIGHT

ROLLBACK

ROW_COUNT

ROWS

SAVEPOINT

SECOND

SELECT

SENSITIVE

SET

SIMILAR

SMALLINT

SOME

SQLCODE

SQLSTATE (2.5.1)

START

SUM

TABLE

THEN

TIME

TIMESTAMP

TO

TRAILING

TRIGGER

TRIM

UNION

UNIQUE

UPDATE

UPDATING

UPPER

USER

USING

VALUE

VALUES

VARCHAR

VARIABLE

VARYING

VIEW

WHEN

WHERE

WHILE

WITH

YEAR

 

Keywords

The following terms have a special meaning in Firebird 2.5 DSQL. Some of them are also reserved words, others are not.

!<

^<

^=

^>

,

:=

!=

!>

(

)

<

<>

=

>

>=

||

~<

~=

~>

ABS

ACCENT

ACOS

ACTION

ACTIVE

ADD

ADMIN

AFTER

ALL

ALTER

ALWAYS

AND

ANY

AS

ASC

ASCENDING

ASCII_CHAR

ASCII_VAL

ASIN

AT

ATAN

ATAN2

AUTO

AUTONOMOUS

AVG

BACKUP

BEFORE

BEGIN

BETWEEN

BIGINT

BIN_AND

BIN_NOT

BIN_OR

BIN_SHL

BIN_SHR

BIN_XOR

BIT_LENGTH

BLOB

BLOCK

BOTH

BREAK

BY

CALLER

CASCADE

CASE

CAST

CEIL

CEILING

CHAR

CHAR_LENGTH

CHAR_TO_UUID

CHARACTER

CHARACTER_LENGTH

CHECK

CLOSE

COALESCE

COLLATE

COLLATION

COLUMN

COMMENT

COMMIT

COMMITTED

COMMON

COMPUTED

CONDITIONAL

CONNECT

CONSTRAINT

CONTAINING

COS

COSH

COT

COUNT

CREATE

CROSS

CSTRING

CURRENT

CURRENT_CONNECTION

CURRENT_DATE

CURRENT_ROLE

CURRENT_TIME

CURRENT_TIMESTAMP

CURRENT_TRANSACTION

CURRENT_USER

CURSOR

DATA

DATABASE

DATE

DATEADD

DATEDIFF

DAY

DEC

DECIMAL

DECLARE

DECODE

DEFAULT

DELETE

DELETING

DESC

DESCENDING

DESCRIPTOR

DIFFERENCE

DISCONNECT

DISTINCT

DO

DOMAIN

DOUBLE

DROP

ELSE

END

ENTRY_POINT

ESCAPE

EXCEPTION

EXECUTE

EXISTS

EXIT

EXP

EXTERNAL

EXTRACT

FETCH

FILE

FILTER

FIRST

FIRSTNAME

FLOAT

FLOOR

FOR

FOREIGN

FREE_IT

FROM

FULL

FUNCTION

GDSCODE

GEN_ID

GEN_UUID

GENERATED

GENERATOR

GLOBAL

GRANT

GRANTED

GROUP

HASH

HAVING

HOUR

IF

IGNORE

IIF

IN

INACTIVE

INDEX

INNER

INPUT_TYPE

INSENSITIVE

INSERT

INSERTING

INT

INTEGER

INTO

IS

ISOLATION

JOIN

KEY

LAST

LASTNAME

LEADING

LEAVE

LEFT

LENGTH

LEVEL

LIKE

LIMBO

LIST

LN

LOCK

LOG

LOG10

LONG

LOWER

LPAD

MANUAL

MAPPING

MATCHED

MATCHING

MAX

MAXIMUM_SEGMENT

MAXVALUE

MERGE

MIDDLENAME

MILLISECOND

MIN

MINUTE

MINVALUE

MOD

MODULE_NAME

MONTH

NAMES

NATIONAL

NATURAL

NCHAR

NEXT

NO

NOT

NULL

NULLIF

NULLS

NUMERIC

OCTET_LENGTH

OF

ON

ONLY

OPEN

OPTION

OR

ORDER

OS_NAME

OUTER

OUTPUT_TYPE

OVER

OVERFLOW

OVERLAY

PAD

PAGE

PAGE_SIZE

PAGES

PARAMETER

PASSWORD

PI

PLACING

PLAN

POSITION

POST_EVENT

POWER

PRECISION

PRESERVE

PRIMARY

PRIVILEGES

PROCEDURE

PROTECTED

RAND

RDB$DB_KEY

READ

REAL

RECORD_VERSION

RECREATE

RECURSIVE

REFERENCES

RELEASE

REPLACE

REQUESTS

RESERV

RESERVING

RESTART

RESTRICT

RETAIN

RETURNING

RETURNING_VALUES

RETURNS

REVERSE

REVOKE

RIGHT

ROLE

ROLLBACK

ROUND

ROW_COUNT

ROW_NUMBER

ROWS

RPAD

SAVEPOINT

SCALAR_ARRAY

SCHEMA

SECOND

SEGMENT

SELECT

SENSITIVE

SEQUENCE

SET

SHADOW

SHARED

SIGN

SIMILAR

SIN

SINGULAR

SINH

SIZE

SKIP

SMALLINT

SNAPSHOT

SOME

SORT

SOURCE

SPACE

SQLCODE

SQLSTATE (2.5.1)

SQRT

STABILITY

START

STARTING

STARTS

STATEMENT

STATISTICS

SUB_TYPE

SUBSTRING

SUM

SUSPEND

TABLE

TAN

TANH

TEMPORARY

THEN

TIME

TIMEOUT

TIMESTAMP

TO

TRAILING

TRANSACTION

TRIGGER

TRIM

TRUNC

TWO_PHASE

TYPE

UNCOMMITTED

UNDO

UNION

UNIQUE

UPDATE

UPDATING

UPPER

USER

USING

UUID_TO_CHAR

VALUE

VALUES

VARCHAR

VARIABLE

VARYING

VIEW

WAIT

WEEK

WEEKDAY

WHEN

WHERE

WHILE

WITH

WORK

WRITE

YEAR

YEARDAY