NON_KEYWORDS option [TSQL]

Function

Turns off individual keywords, allowing their use as identifiers.

Allowed values

String

Default

Empty string.

Description

This option turns off individual keywords. If you have an identifier in your database that is now a keyword, you can either add double quotes around the identifier in all applications or scripts, or you can turn off the keyword using the NON_KEYWORDS option.

The following statement prevents TRUNCATE and SYNCHRONIZE from being recognized as keywords:

SET OPTION NON_KEYWORDS = 'TRUNCATE, SYNCHRONIZE'

Each new setting of this option replaces the previous setting. The following statement clears all previous settings.

SET OPTION NON_KEYWORDS =

A side effect of the options is that SQL statements using a turned off keyword cannot be used: they produce a syntax error.