13.07.2015 Views

Caché Transact-SQL (TSQL) Migration Guide - InterSystems ...

Caché Transact-SQL (TSQL) Migration Guide - InterSystems ...

Caché Transact-SQL (TSQL) Migration Guide - InterSystems ...

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

5T<strong>SQL</strong> SettingsSettings are used to tailor the behavior of the compiler and colorizer. The T<strong>SQL</strong> configuration options are part of the standard<strong>Caché</strong> configuration. Most are settable using the Management Portal.<strong>Caché</strong> supports the following T<strong>SQL</strong> settings:• DIALECT (default is Sybase)• ANSI_NULLS (default is ON)• TRACE• CASEINSCOMPARE (String comparison is not case-sensitive. Default is ON)• QUOTED_IDENTIFIER (default is ON)Go into the <strong>Caché</strong> Management Portal. Go to [System] > [Configuration] > [<strong>SQL</strong> Settings], then select T<strong>SQL</strong> CompatibilitySettings. Here you can specify the DIALECT (Sybase or MS<strong>SQL</strong>, default is Sybase), and turn on or off the ANSI_NULLS,CASEINSCOMPARE, and QUOTED_IDENTIFIER settings. The Management Portal default for these three settings is “OFF”.These values are used to set the corresponding ^%SYS("tsql","SET",...) global array values.5.1 DIALECTThe DIALECT configuration option allows you to select the <strong>Transact</strong>-<strong>SQL</strong> dialect. The available options are Sybase andMS<strong>SQL</strong>. The default is Sybase. This option is set using the <strong>Caché</strong> Management Portal.If DIALECT=MS<strong>SQL</strong>: a DECLARE statement binds host variable values.If DIALECT=Sybase: host variable values are refreshed for each cursor OPEN.5.2 TRACEThe TRACE configuration option controls the behavior of the T<strong>SQL</strong> compiler. When a method is compiled with TRACEactive, running this method will log traced messages to the active log file, by default. The active log file is located in thesame namespace as CACHE.DAT, and is named using the current process number.You can activate (=1) or deactivate (=0) TRACE systemwide using the following <strong>Caché</strong> ObjectScript command:SET ^%sys("tsql","TRACE")=1<strong>Caché</strong> <strong>Transact</strong>-<strong>SQL</strong> (T<strong>SQL</strong>) <strong>Migration</strong> <strong>Guide</strong> 33

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!