0

I just reading the article at https://technet.microsoft.com/en-us/library/ms176027(v=sql.105).aspx . For a delimited identifier, if I use bracket [ and ] as the delimiter, then what if I include left or right bracket in the identifier itself, how to escape them?

Thanks

alancc
  • 487
  • 2
  • 24
  • 68

1 Answers1

1

The article that you linked already gave you the answer. Look at the first example:

CREATE TABLE [Employee]]] 

However, I wouldn't use an identifier with square brackets. Also consider using the more standard way of enclosing identifiers in double quotes rather than the square brackets. This way if you copy your queries from SQL Server to another database, they will work.

Racil Hilan
  • 24,690
  • 13
  • 50
  • 55