The basic symbols of keywords and operators in the SQL
language are single-byte characters7 that are part of all character sets supported by the IBM
relational database products. Characters of the language are classified
as letters, digits, or special characters.
A letter is any of the 26 uppercase (A through Z) and 26
lowercase (a through z) letters of the English alphabet.
8
A digit is any of the characters 0 through 9.
A special character is any of the characters listed below:
9
| space
| -
| minus sign
|
| "
| quotation mark or double-quote
| .
| period
|
| %
| percent
| /
| slash
|
| &
| ampersand
| :
| colon
|
| '
| apostrophe or single quote
| ;
| semicolon
|
| (
| left parenthesis
| <
| less than
|
| )
| right parenthesis
| =
| equals
|
| *
| asterisk
| >
| greater than
|
| +
| plus sign
| ?
| question mark
|
| ,
| comma
| _
| underline or underscore
|
| | 10
| vertical bar
|
|
|
Footnotes:
- 7
-
Note that if the SQL statement is encoded as UCS-2 data, all characters of the
statement except for string constants will be converted to single-byte
characters prior to processing. Tokens representing string constants
will be processed as UCS-2 graphic strings without conversion to
single-byte.
- 8
-
Letters also include three code points reserved as alphabetic extenders for
national languages (#, @, and $ in the United States). These three code
points should be avoided because they represent different characters depending
on the CCSID.
- 9
-
The not symbol (¬) and the exclamation point symbol (!) are also
special characters used by DB2 UDB for AS/400. You should avoid using
them because they are variant characters.
- 10
-
Using the vertical bar (|) character might inhibit code portability between
IBM relational database products. It is preferable to use the CONCAT
operator instead of the concatenation operator (||). Use of the
vertical bar should be avoided because it is a variant character.
[ Top of Page | Previous Page | Next Page | Table of Contents | Index ]