T-SQL language elements for dedicated SQL pool in Azure Synapse Analytics
Links to the documentation for T-SQL language elements supported in dedicated SQL pool.
Core elements
- syntax conventions
- object naming rules
- reserved keywords
- collations
- comments
- constants
- data types
- EXECUTE
- expressions
- KILL
- IDENTITY property workaround
- USE
Batches, control-of-flow, and variables
- BEGIN...END
- BREAK
- DECLARE @local_variable
- IF...ELSE
- RAISERROR
- SET@local_variable
- THROW
- TRY...CATCH
- WHILE
Operators
Wildcard character(s) to match
- = (Equals)
- > (Greater than)
- < (Less than)
- >= (Great than or equal to)
- <= (Less than or equal to)
- <> (Not equal to)
- != (Not equal to)
- AND
- BETWEEN
- EXISTS
- IN
- IS [NOT] NULL
- LIKE
- NOT
- OR
Bitwise operators
- & (Bitwise AND)
- | (Bitwise OR)
- ^ (Bitwise exclusive OR)
- ~ (Bitwise NOT)
- ^= (Bitwise Exclusive OR EQUALS)
- |= (Bitwise OR EQUALS)
- &= (Bitwise AND EQUALS)
Functions
- @@DATEFIRST
- @@ERROR
- @@LANGUAGE
- @@SPID
- @@TRANCOUNT
- @@VERSION
- ABS
- ACOS
- ASCII
- ASIN
- ATAN
- ATN2
- BINARY_CHECKSUM
- CASE
- CAST and CONVERT
- CEILING
- CHAR
- CHARINDEX
- CHECKSUM
- COALESCE
- COL_NAME
- COLLATIONPROPERTY
- CONCAT
- COS
- COT
- COUNT
- CONCAT_WS
- COUNT_BIG
- CUME_DIST
- CURRENT_TIMESTAMP
- CURRENT_USER
- DATABASEPROPERTYEX
- DATALENGTH
- DATEADD
- DATEDIFF
- DATEFROMPARTS
- DATENAME
- DATEPART
- DATETIME2FROMPARTS
- DATETIMEFROMPARTS
- DATETIMEOFFSETFROMPARTS
- DAY
- DB_ID
- DB_NAME
- DEGREES
- DENSE_RANK
- DIFFERENCE
- EOMONTH
- ERROR_MESSAGE
- ERROR_NUMBER
- ERROR_PROCEDURE
- ERROR_SEVERITY
- ERROR_STATE
- EXP
- FIRST_VALUE
- FLOOR
- GETDATE
- GETUTCDATE
- HAS_DBACCESS
- HASHBYTES
- INDEXPROPERTY
- ISDATE
- ISNULL
- ISNUMERIC
- LAG
- LAST_VALUE
- LEAD
- LEFT
- LEN
- LOG
- LOG10
- LOWER
- LTRIM
- MAX
- MIN
- MONTH
- NCHAR
- NTILE
- NULLIF
- OBJECT_ID
- OBJECT_NAME
- OBJECTPROPERTY
- OIBJECTPROPERTYEX
- ODBCS scalar functions
- OVER clause
- PARSENAME
- PATINDEX
- PERCENTILE_CONT
- PERCENTILE_DISC
- PERCENT_RANK
- PI
- POWER
- QUOTENAME
- RADIANS
- RAND
- RANK
- REPLACE
- REPLICATE
- REVERSE
- RIGHT
- ROUND
- ROW_NUMBER
- RTRIM
- SCHEMA_ID
- SCHEMA_NAME
- SERVERPROPERTY
- SESSION_USER
- SIGN
- SIN
- SMALLDATETIMEFROMPARTS
- SOUNDEX
- SPACE
- SQL_VARIANT_PROPERTY
- SQRT
- SQUARE
- STATS_DATE
- STDEV
- STDEVP
- STR
- STRING_AGG
- STRING_SPLIT
- STUFF
- SUBSTRING
- SUM
- SUSER_SNAME
- SWITCHOFFSET
- SYSDATETIME
- SYSDATETIMEOFFSET
- SYSTEM_USER
- SYSUTCDATETIME
- TAN
- TERTIARY_WEIGHTS
- TIMEFROMPARTS
- TRIM
- TODATETIMEOFFSET
- TYPE_ID
- TYPE_NAME
- TYPEPROPERTY
- UNICODE
- UPPER
- USER
- USER_NAME
- VAR
- VARP
- YEAR
- XACT_STATE
Transactions
Diagnostic sessions
Procedures
- sp_addrolemember
- sp_columns
- sp_configure
- sp_datatype_info_90
- sp_droprolemember
- sp_execute
- sp_executesql
- sp_fkeys
- sp_pdw_add_network_credentials
- sp_pdw_database_encryption
- sp_pdw_database_encryption_regenerate_system_keys
- sp_pdw_log_user_data_masking
- sp_pdw_remove_network_credentials
- sp_pkeys
- sp_prepare
- sp_rename (preview)
- sp_spaceused
- sp_special_columns_100
- sp_sproc_columns
- sp_statistics
- sp_tables
- sp_unprepare
SET statements
- SET ANSI_DEFAULTS
- SET ANSI_NULL_DFLT_OFF
- SET ANSI_NULL_DFLT_ON
- SET ANSI_NULLS
- SET ANSI_PADDING
- SET ANSI_WARNINGS
- SET ARITHABORT
- SET ARITHIGNORE
- SET CONCAT_NULL_YIELDS_NULL
- SET DATEFIRST
- SET DATEFORMAT
- SET FMTONLY
- SET IMPLICIT_TRANSACITONS
- SET LOCK_TIMEOUT
- SET NUMBERIC_ROUNDABORT
- SET QUOTED_IDENTIFIER
- SET ROWCOUNT
- SET TEXTSIZE
- SET TRANSACTION ISOLATION LEVEL
- SET XACT_ABORT
Next steps
For more reference information, see T-SQL statements in dedicated SQL pool, and System views in dedicated SQL pool.