9.4.2 Authorization identifier specification rules
The authorization identifier specification rules are as follows:
-
Characters that can be used in authorization identifiers are single-byte uppercase letters, single-byte lowercase letters, single-byte numbers, the backslash (\), the hash mark (#), and the at sign (@).
-
When you use lowercase letters for an authorization identifier, enclose the authorization identifier in double quotation marks (").
Example: CREATE USER "ADBuser02" ...
If lowercase letters are not enclosed in double quotation marks ("), they are treated as uppercase letters. For example, specification -u ADBuser02 is treated as -u ADBUSER02.
-
Because authorization identifiers are specified as names, we recommend that you enclose them in double quotation marks (").
-
You cannot specify ALL, HADB, MASTER, or PUBLIC as an authorization identifier.
-
You can specify a maximum of 100 characters (100 bytes) as an authorization identifier.
-
For further details about authorization identifier specification rules, see Specifying names in SQL writing conventions under SQL Basics in the manual HADB SQL Reference.
- ■ Rules for specifying an authorization identifier in the -u option of a command
-
The following rules apply when you are specifying an authorization identifier in the -u option of a command.
-
When an authorization identifier contains lowercase letters
If you are specifying an authorization identifier that contains lowercase letters, you must either enclose the authorization identifier with a backslash and double quotation mark (\"), or you must enclose the authorization identifier in double quotation marks (") and then enclose the entire string in single quotation marks (').
Examples:
-u \"ADBuser02\"
-u '"ADBuser02"'
If the authorization identifier is not specified as shown above, all characters are treated as uppercase letters. For example, specification -u ADBuser02 is treated as -u ADBUSER02.
-
When an authorization identifier contains a backslash (\)
The backslash (\) is a special character used by the shell for a different purpose. Therefore, when an authorization identifier contains a backslash (\), specify an escape character before the backslash (\).
Examples:
• If you specify ADBUSER\01 as an authorization identifier: -u ADBUSER\\01
• If you specify ADBuser\01 as an authorization identifier: -u \"ADBuser\\01\"
In the above examples, the backslash (\) is specified as an escape character.
-