Delimited Identifiers

By default, the character set of a valid SQL identifier is restricted to letters, digits, underscore, and dollar-sign symbols. If you set the DELIMIDENT environment variable, however, SQL identifiers can also include additional characters from the code set implied by the setting of the DB_LOCALE environment variable.

Delimited Identifier

1  "
1+ 
1 letter
1 digit
1 underscore
1 other_character
2  "

Element Description Restrictions Syntax
digit Integer in the range 0 to 9 Cannot be the first character Literal Number
letter Letter that forms part of the delimited identifier Letters in delimited identifiers are case-sensitive Literal value entered from the keyboard.
other _character Nonalphanumeric character, such as #, $, or blank space Must be an element in the code set of the database locale Literal value entered from the keyboard.
underscore Underscore ( _ ) symbol in the delimited identifier Cannot include more than 128 Literal value entered from the keyboard.

If the database supports delimited identifiers, any double quotation marks ( " ) enclose an SQL identifier in your code, and only single ( ' ) quotation marks, rather than double ( " ) quotation marks, delimit character-string literals.

Delimited identifiers enable you to declare names that are otherwise identical to SQL keywords, such as TABLE, WHERE, DECLARE, and so on. The only type of object for which you cannot specify a delimited identifier is a database name.

Letters in delimited identifiers are case sensitive. If you are using the default locale, letter must be an upper- or lowercase character in the range a to z or A to Z (in the ASCII code set). If you are using a nondefault locale, letter must be an alphabetic character that the locale supports. For more information, see Support for Non-ASCII Characters in Delimited Identifiers (GLS).

Delimited identifiers are compliant with the ANSI/ISO standard for SQL.

When you create a database object, avoid including leading blank spaces or other white-space characters between the first delimiting quotation mark and the first nonblank character of the delimited identifier. (Otherwise, you might not be able to reference the object in some contexts.)

If the name of a database server is a delimited identifier or if it includes uppercase letters, that database server cannot participate in distributed DML operations. To avoid this restriction, use only undelimited names that include no uppercase letters when you declare the name or the alias of a database server.