Identifiers are names for database objects such as databases, tables, views, columns, indexes, triggers, procedures, defaults, rules, and cursors.
The limit for the length of object names or identifiers is 255 bytes for regular identifiers, and 253 bytes for delimited identifiers. The limit applies to most user-defined identifiers including table name, column name, index name and so on. Due to the expanded limits, some system tables (catalogs) and built-in functions have been expanded.
For variables, “@” count as 1 byte, and the allowed name for it is 254 bytes long.
Listed below are the identifiers, system tables, and built-in functions that are affected these limits.
Table name
Column name
Index name
View name
User-defined datatype
Trigger name
Default name
Rule name
Constraint name
Procedure name
Variable name
JAR name
Name of LWP or dynamic statement
Function name
Name of the time range
Application context name
Most user-defined SAP ASE identifiers can be a maximum of 255 bytes in length, whether single-byte or multibyte characters are used. Others can be a mximum of 30 bytes. Refer to the Transact-SQL User’s Guide for a list of both 255-byte and 30-byte identifiers.
The first character of an identifier must be either an alphabetic character, as defined in the current character set, or the underscore (_ ) character.
Subsequent characters can include letters, numbers, the symbols #, @, _, and currency symbols such as $ (dollars), ¥ (yen), and £ (pound sterling). Identifiers cannot include special characters such as !, %, ^, &, *, and . or embedded spaces.
You cannot use a reserved word, such as a Transact-SQL command, as an identifier.
You cannot use the dash symbol ( – ) as an identifier.