Show MenuHide Menu

Delimiting identifiers in sql server

September 28, 2015

There are two means of delimiting identifiers in T-SQL:

1) Using Square Brackets e.g. [MyColumn] this is proprietary to T-SQL

2) The ANSI standard way using double quotes, “MyColumn”

But delimiting is only required when an identifier does not conform to the rules for formatting identifiers. These rules are that the first character must be an upper or lower case letter, underscore, @ sign or number sign. The identifier cannot be a reserved word, no embedded spaces and no supplementary characters. If the identifier does not meet these requirements it must be delimited.