The names of databases, tables, other objects or workload names specified in the CHECK command can consist of the following inclusive characters:
- Lowercase alphabet (a … z)
- Uppercase alphabet (A … Z)
- Digits (0 … 9)
- The following special characters.
Special characters … Include … Parentheses, braces, and brackets - ( ) (parentheses)
- { } (curly braces)
- [ ] (square brackets)
- < > (angle brackets)
Punctuation marks - ` (grave accent)
- ! (exclamation point)
- ; (semicolon)
- : (colon)
- ' (apostrophe)
- ? (question mark)
- . (period)
- , (comma)
Other - | (vertical line)
- ~ (tilde)
- @ (at sign)
- $ (dollar sign)
- = (equals sign)
- % (percent sign)
- + (plus)
- # (number sign)
- ^ (circumflex accent or caret)
- & (ampersand)
- * (asterisk)
- - (hyphen-minus)
- _ (low line or underscore)
- / (forward slash)
- \ (backward slash)
Workload names can only include the following: letters, numbers, underscores, hyphens-minuses, and spaces.
You must specify any name containing one or more special characters or blank spaces within apostrophes or double quotation marks, except for the following:
- ? (question mark)
- % (percent sign)
- $ (dollar sign)
- _ (low line or underscore)
- [ ](square brackets)
- # (number sign)
For more information on creating names, see “Basic SQL Syntax and Lexicon” in SQL Fundamentals.
Examples of Database and Table Names
The following examples show valid database or table names:
- Table1
- MYTABLE10
- $$MyAccount
- #Your_Account_$100
- %mydatabase?
- %
- ???
The following examples show irregular but acceptable names:
- '123'
- "First&Second table"
- 'my db1'
The following examples show unacceptable and non-valid names:
- 123
- First&Second table
- my db1