SET Statements

statements
#tsql#statements

Category

Statements

Analytics Platform System (PDW)

The Transact-SQL programming language provides several SET statements that change the current session handling of specific information. The SET statements are grouped into the categories shown in the following table.

For information about setting local variables with the SET statement, see

SET @local_variable

(Transact-SQL).

Date and time statements

SET DATEFIRST

SET DATEFORMAT

Locking

statements

SET DEADLOCK_PRIORITY

SET LOCK_TIMEOUT

Miscellaneous

statements

SET CONCAT_NULL_YIELDS_NULL

SET CURSOR_CLOSE_ON_COMMIT

SET FIPS_FLAGGER

SET IDENTITY_INSERT

SET LANGUAGE

SET OFFSETS

SET QUOTED_IDENTIFIER

Query Execution

Statements

SET ARITHABORT

SET ARITHIGNORE

SET FMTONLY

Note: This feature will be removed in a future version of SQL Server. Avoid using this feature in new development work, and plan to modify applications that currently use this feature.

Category

Statements

SET NOCOUNT

SET NOEXEC

SET NUMERIC_ROUNDABORT

SET PARSEONLY

SET QUERY_GOVERNOR_COST_LIMIT

SET RESULT SET CACHING

(Preview)

Note: This feature applies to Azure Synapse Analytics only.

SET ROWCOUNT

SET TEXTSIZE

ISO Settings statements

SET ANSI_DEFAULTS

SET ANSI_NULL_DFLT_OFF

SET ANSI_NULL_DFLT_ON

SET ANSI_NULLS

SET ANSI_PADDING

SET ANSI_WARNINGS

Statistics

statements

SET FORCEPLAN

SET SHOWPLAN_ALL

SET SHOWPLAN_TEXT

SET SHOWPLAN_XML

SET STATISTICS IO

SET STATISTICS XML

SET STATISTICS PROFILE

SET STATISTICS TIME

Transactions

statements

SET IMPLICIT_TRANSACTIONS

SET REMOTE_PROC_TRANSACTIONS

Category

Statements

sp_executesql user options sp_configure sp_configure