Skip to main content
Skip table of contents

Supported Microsoft SQL Server and Microsoft Azure SQL Database Built-in Functions

A complete list of supported built-in functions for Microsoft SQL Server and Microsoft Azure SQL Database is available in the SYSADMIN.SourceSupportedSystemFunctions system table.

To retrieve the list, use the following query:

SQL
SELECT * FROM SYSADMIN.SourceSupportedSystemFunctions WHERE translator = 'sqlserver';;

Version Support

  • We support versions 14, 15, and 16 of Microsoft SQL Server.
    Accordingly, refer to these versions when working with Microsoft SQL Server.

  • Microsoft Azure SQL Database uses the same database engine as Microsoft SQL Server, but follows a managed "evergreen" versioning model.
    Version 12 reflects the capabilities and compatibility level used in Azure environments.
    Therefore, for Azure SQL Database, refer to version 12.

If a built-in function is not listed, it can be registered manually as a foreign function.
For instructions, see the “Built-in Functions” section on the Foreign Functions page.

List of Supported Functions

Function name

Supported in

Description

Azure

v14

v15

v16

@@CONNECTIONS

(tick)

(tick)

(tick)

(tick)

Returns the number of attempted connections - both successful and unsuccessful - since SQL Server was last started

@@CPU_BUSY

(tick)

(tick)

(tick)

(tick)

Returns the amount of time that SQL Server has spent in active operation since its latest start

@@CURSOR_ROWS

(tick)

(tick)

(tick)

(tick)

Returns the number of qualifying rows currently in the last cursor opened on the connection

@@DBTS

(tick)

(tick)

(tick)

(tick)

Returns the value of the current timestamp data type for the current database. The current database will have a guaranteed unique timestamp value

@@ERROR

(tick)

(tick)

(tick)

(tick)

Returns the error number for the last Transact-SQL statement executed

@@FETCH_STATUS

(tick)

(tick)

(tick)

(tick)

Returns the status of the last cursor FETCH statement issued against any cursor currently opened by the connection

@@IDENTITY

(tick)

(tick)

(tick)

(tick)

Returns the last-inserted identity value

@@IDLE

(tick)

(tick)

(tick)

(tick)

Returns the time that SQL Server has been idle since it was last started

@@IO_BUSY

(tick)

(tick)

(tick)

(tick)

Returns the time that SQL Server has spent performing input and output operations since SQL Server was last started

@@LANGID

(tick)

(tick)

(tick)

(tick)

Returns the local language identifier (ID) of the language that is currently being used

@@LANGUAGE

(tick)

(tick)

(tick)

(tick)

Returns the name of the language currently being used

@@LOCK_TIMEOUT

(tick)

(tick)

(tick)

(tick)

Returns the current lock time-out setting in milliseconds for the current session

@@MAX_CONNECTIONS

(tick)

(tick)

(tick)

(tick)

Returns the maximum number of simultaneous user connections allowed on an instance of SQL Server. The number returned is not necessarily the number currently configured

@@MAX_PRECISION

(tick)

(tick)

(tick)

(tick)

Returns the precision level used by decimal and numeric data types as currently set in the server

@@NESTLEVEL

(tick)

(tick)

(tick)

(tick)

Returns the nesting level of the current stored procedure execution (initially 0) on the local server

@@OPTIONS

(tick)

(tick)

(tick)

(tick)

Returns information about the current SET options

@@PACKET_ERRORS

(tick)

(tick)

(tick)

(tick)

Returns the number of network packet errors that have occurred on SQL Server connections since SQL Server was last started

@@PACK_RECEIVED

(tick)

(tick)

(tick)

(tick)

Returns the number of input packets read from the network by SQL Server since it was last started

@@PACK_SENT

(tick)

(tick)

(tick)

(tick)

Returns the number of output packets written to the network by SQL Server since it was last started

@@PROCID

(tick)

(tick)

(tick)

(tick)

Returns the object identifier (ID) of the current Transact-SQL module

@@REMSERVER

(tick)

(tick)

(tick)

(tick)

Returns the name of the remote SQL Server database server as it appears in the login record

@@ROWCOUNT

(tick)

(tick)

(tick)

(tick)

Returns the number of rows affected by the last statement. If the number of rows is more than 2 billion, use ROWCOUNT_BIG

@@SERVERNAME

(tick)

(tick)

(tick)

(tick)

Returns the name of the local server that is running SQL Server

@@SERVICENAME

(tick)

(tick)

(tick)

(tick)

Returns the name of the registry key under which SQL Server is running

@@SPID

(tick)

(tick)

(tick)

(tick)

Returns the session ID of the current user process

@@TEXTSIZE

(tick)

(tick)

(tick)

(tick)

Returns the current value of the TEXTSIZE option

@@TIMETICKS

(tick)

(tick)

(tick)

(tick)

Returns the number of microseconds per tick

@@TOTAL_ERRORS

(tick)

(tick)

(tick)

(tick)

Returns the number of disk write errors encountered by SQL Server since SQL Server last started

@@TOTAL_READ

(tick)

(tick)

(tick)

(tick)

Returns the number of disk reads, not cache reads, by SQL Server since SQL Server was last started

@@TOTAL_WRITE

(tick)

(tick)

(tick)

(tick)

Returns the number of disk writes by SQL Server since SQL Server was last started

@@TRANCOUNT

(tick)

(tick)

(tick)

(tick)

Returns the number of BEGIN TRANSACTION statements that have occurred on the current connection

@@VERSION

(tick)

(tick)

(tick)

(tick)

Returns system and build information for the current installation of SQL Server

ABS

(tick)

(tick)

(tick)

(tick)

Returns the absolute (positive) value of the specified numeric expression

ACOS

(tick)

(tick)

(tick)

(tick)

Arccosine function returns the angle, in radians, whose cosine is the specified float expression

APPLOCK_MODE

(tick)

(tick)

(tick)

(tick)

Returns the lock mode held by the lock owner on a particular application resource

APPLOCK_TEST

(tick)

(tick)

(tick)

(tick)

Returns information as to whether or not a lock can be granted on a particular application resource, for a specified lock owner, without acquisition of the lock

APPROX_PERCENTILE_CONT

(tick)

(tick)

(tick)

(tick)

Returns an approximate interpolated value from the set of values in a group based on percentile value and sort specification

APPROX_PERCENTILE_DISC

(tick)

(tick)

(tick)

(tick)

Returns the value from the set of values in a group based on the provided percentile and sort specification

APP_NAME

(tick)

(tick)

(tick)

(tick)

Returns the application name for the current session, if the application sets that name value

ASCII

(tick)

(tick)

(tick)

(tick)

Returns the ASCII code value of the leftmost character of a character expression

ASIN

(tick)

(tick)

(tick)

(tick)

Arcsine function returns the angle, in radians, whose sine is the specified float expression

ASSEMBLYPROPERTY

(tick)

(tick)

(tick)

(tick)

Returns information about a property of an assembly

ASYMKEYPROPERTY

(tick)

(tick)

(tick)

(tick)

Returns the property of an asymmetric key

ASYMKEY_ID

(tick)

(tick)

(tick)

(tick)

Returns the ID of an asymmetric key

ATAN

(tick)

(tick)

(tick)

(tick)

Arctangent function returns the angle, in radians, whose tangent is a specified float expression

ATN2

(tick)

(tick)

(tick)

(tick)

Returns the angle, in radians, between the positive x-axis and the ray from the origin to the point (y, x)

AVG

(tick)

(tick)

(tick)

(tick)

Returns the average of the values in a group. Ignores null values

BINARY_CHECKSUM

(tick)

(tick)

(tick)

(tick)

Returns the binary checksum value computed over a row of a table or over a list of expressions

BIT_COUNT

(minus)

(minus)

(minus)

(tick)

Takes one parameter and returns the number of bits set to 1 in that parameter as a bigint type

CAST

(tick)

(tick)

(tick)

(tick)

Convert an expression of one data type to another

CEILING

(tick)

(tick)

(tick)

(tick)

Returns the smallest integer greater than, or equal to, the specified numeric expression

CERTENCODED

(tick)

(tick)

(tick)

(tick)

Returns the public portion of a certificate in binary format

CERTPRIVATEKEY

(tick)

(tick)

(tick)

(tick)

Returns the private key of a certificate in binary format

CERTPROPERTY

(tick)

(tick)

(tick)

(tick)

Returns the value of a specified certificate property

CERT_ID

(tick)

(tick)

(tick)

(tick)

Returns the ID value of a certificate

CHAR

(tick)

(tick)

(tick)

(tick)

Returns the single-byte character with the specified integer code, as defined by the character set and encoding of the default collation of the current database

CHARINDEX

(tick)

(tick)

(tick)

(tick)

Searches for one character expression inside a second character expression, returning the starting position of the first expression if found

CHECKSUM

(tick)

(tick)

(tick)

(tick)

Returns the checksum value computed over a table row, or over an expression list. Use CHECKSUM to build hash indexes

CHECKSUM_AGG

(tick)

(tick)

(tick)

(tick)

Returns the checksum of the values in a group. CHECKSUM_AGG ignores null values

CHOOSE

(tick)

(tick)

(tick)

(tick)

Returns the item at the specified index from a list of values in SQL Server

COLLATIONPROPERTY

(tick)

(tick)

(tick)

(tick)

Returns the requested property of a specified collation

COLUMNPROPERTY

(tick)

(tick)

(tick)

(tick)

Returns column or parameter information

COLUMNS_UPDATED

(tick)

(tick)

(tick)

(tick)

Returns a varbinary bit pattern indicating the inserted or updated columns of a table or view

COL_LENGTH

(tick)

(tick)

(tick)

(tick)

Returns the defined length of a column, in bytes

COL_NAME

(tick)

(tick)

(tick)

(tick)

Returns the name of a table column, based on the table identification number and column identification number values of that table column

COMPRESS

(minus)

(tick)

(tick)

(tick)

Compresses the input expression, using the Gzip algorithm. The function returns a byte array

CONCAT

(tick)

(tick)

(tick)

(tick)

Returns a string resulting from the concatenation, or joining, of two or more string values in an end-to-end manner

CONCAT_WS

(minus)

(tick)

(tick)

(tick)

Returns a string resulting from the concatenation, or joining, of two or more string values in an end-to-end manner. It separates those concatenated string values with the delimiter specified in the first function argument

CONNECTIONPROPERTY

(tick)

(tick)

(tick)

(tick)

For a request that comes in to the server, this function returns information about the connection properties of the unique connection which supports that request

CONTEXT_INFO

(tick)

(tick)

(tick)

(tick)

This function returns the context_info value either set for the current session or batch, or derived through use of the SET CONTEXT_INFO statement

COS

(tick)

(tick)

(tick)

(tick)

Returns the trigonometric cosine of the specified angle - measured in radians - in the specified expression

COT

(tick)

(tick)

(tick)

(tick)

Returns the trigonometric cotangent of the specified angle - in radians - in the specified float expression

COUNT

(tick)

(tick)

(tick)

(tick)

Returns the number of items found in a group

COUNT_BIG

(tick)

(tick)

(tick)

(tick)

Returns the number of items found in a group

CRYPT_GEN_RANDOM

(tick)

(tick)

(tick)

(tick)

Returns a cryptographic, randomly-generated hexadecimal number with a length of a specified number of bytes, generated by the Crypto API (CAPI)

CUME_DIST

(tick)

(tick)

(tick)

(tick)

Calculates the cumulative distribution of a value within a group of values

CURRENT_REQUEST_ID

(tick)

(tick)

(tick)

(tick)

Returns the ID of the current request within the current session

CURRENT_TIMESTAMP

(tick)

(tick)

(tick)

(tick)

Current date and time

CURRENT_TIMEZONE

(tick)

(minus)

(tick)

(tick)

This function returns the name of the time zone observed by a server or an instance. For SQL Managed Instance, return value is based on the time zone of the instance itself assigned during instance creation, not the time zone of the underlying operating system

CURRENT_TIMEZONE_ID

(tick)

(minus)

(minus)

(tick)

This function returns the ID of the time zone observed by a server or an instance. For Azure SQL Managed Instance, return value is based on the time zone of the instance itself assigned during instance creation, not the time zone of the underlying operating system

CURRENT_TRANSACTION_ID

(minus)

(tick)

(tick)

(tick)

Returns the transaction ID of the current transaction in the current session

CURRENT_USER

(tick)

(tick)

(tick)

(tick)

Returns the name of the current user

CURSOR_STATUS

(tick)

(tick)

(tick)

(tick)

Shows whether or not a cursor declaration has returned a cursor and result set

DATABASEPROPERTYEX

(tick)

(tick)

(tick)

(tick)

Returns the current setting of the specified database option or property

DATABASE_PRINCIPAL_ID

(tick)

(tick)

(tick)

(tick)

Returns the ID number of a principal in the current database

DATALENGTH

(tick)

(tick)

(tick)

(tick)

Returns the number of bytes used to represent any expression

DATEADD

(tick)

(tick)

(tick)

(tick)

This function adds a number (a signed integer) to a datepart of an input date, and returns a modified date/time value. For example, you can use this function to find the date that is 7000 minutes from today: number = 7000, datepart = minute, date = today

DATEDIFF

(tick)

(tick)

(tick)

(tick)

This function returns the count (as a signed integer value) of the specified datepart boundaries crossed between the specified startdate and enddate

DATEDIFF_BIG

(minus)

(tick)

(tick)

(tick)

This function returns the count (as a signed big integer value) of the specified datepart boundaries crossed between the specified startdate and enddate

DATEFROMPARTS

(tick)

(tick)

(tick)

(tick)

This function returns a date value that maps to the specified year, month, and day values

DATENAME

(tick)

(tick)

(tick)

(tick)

This function returns a character string representing the specified datepart of the specified date

DATEPART

(tick)

(tick)

(tick)

(tick)

This function returns an integer representing the specified datepart of the specified date

DATETIME2FROMPARTS

(tick)

(tick)

(tick)

(tick)

This function returns a datetime2 value for the specified date and time arguments. The returned value has a precision specified by the precision argument

DATETIMEFROMPARTS

(tick)

(tick)

(tick)

(tick)

This function returns a datetime value for the specified date and time arguments

DATETIMEOFFSETFROMPARTS

(tick)

(tick)

(tick)

(tick)

Returns a datetimeoffset value for the specified date and time arguments. The returned value has a precision specified by the precision argument, and an offset as specified by the offset arguments

DATETRUNC

(tick)

(minus)

(minus)

(tick)

The DATETRUNC function returns an input date truncated to a specified datepart

DATE_BUCKET

(tick)

(minus)

(minus)

(tick)

This function returns the date-time value corresponding to the start of each date-time bucket from the timestamp defined by the origin parameter, or the default origin value of 1900-01-01 00:00:00.000 if the origin parameter isn't specified

DAY

(tick)

(tick)

(tick)

(tick)

This function returns an integer that represents the day (day of the month) of the specified date

DB_ID

(tick)

(tick)

(tick)

(tick)

Returns the database identification (ID) number of a specified database

DB_NAME

(tick)

(tick)

(tick)

(tick)

Returns the name of a specified database

DECOMPRESS

(minus)

(tick)

(tick)

(tick)

Decompresses an input expression value, using the Gzip algorithm. DECOMPRESS returns a byte array

DECRYPTBYASYMKEY

(tick)

(tick)

(tick)

(tick)

Decrypts data with an asymmetric key

DECRYPTBYCERT

(tick)

(tick)

(tick)

(tick)

Uses the private key of a certificate to decrypt encrypted data

DECRYPTBYKEY

(tick)

(tick)

(tick)

(tick)

Uses a symmetric key to decrypt data

DECRYPTBYKEYAUTOASYMKEY

(tick)

(tick)

(tick)

(tick)

Decrypts encrypted data - first decrypts a symmetric key with a separate asymmetric key, and then decrypts the encrypted data with the symmetric key extracted in the first "step"

DECRYPTBYKEYAUTOCERT

(tick)

(tick)

(tick)

(tick)

Decrypts data with a symmetric key. That symmetric key automatically decrypts with a certificate

DECRYPTBYPASSPHRASE

(tick)

(tick)

(tick)

(tick)

Decrypts data originally encrypted with a passphrase

DEGREES

(tick)

(tick)

(tick)

(tick)

Returns the corresponding angle, in degrees, for an angle specified in radians

DENSE_RANK

(tick)

(tick)

(tick)

(tick)

returns the rank of each row within a result set partition, with no gaps in the ranking values

DIFFERENCE

(tick)

(tick)

(tick)

(tick)

Returns an integer value measuring the difference between the SOUNDEX() values of two different character expressions

EDGE_ID_FROM_PARTS

(minus)

(tick)

(tick)

(tick)

Returns the character representation (JSON) of the edge ID for a given object ID and graph ID

ENCRYPTBYASYMKEY

(tick)

(tick)

(tick)

(tick)

Encrypts data with an asymmetric key

ENCRYPTBYCERT

(tick)

(tick)

(tick)

(tick)

Encrypts data with the public key of a certificate

ENCRYPTBYKEY

(tick)

(tick)

(tick)

(tick)

Encrypts data with a symmetric key

ENCRYPTBYPASSPHRASE

(tick)

(tick)

(tick)

(tick)

Encrypt data with a passphrase using the TRIPLE DES algorithm with a 128 key bit length

EOMONTH

(tick)

(tick)

(tick)

(tick)

This function returns the last day of the month containing a specified date, with an optional offset

ERROR_LINE

(tick)

(tick)

(tick)

(tick)

Returns the line number of occurrence of an error that caused the CATCH block of a TRY...CATCH construct to execute

ERROR_MESSAGE

(tick)

(tick)

(tick)

(tick)

Returns the message text of the error that caused the CATCH block of a TRY...CATCH construct to execute

ERROR_NUMBER

(tick)

(tick)

(tick)

(tick)

Returns the error number of the error that caused the CATCH block of a TRY...CATCH construct to execute

ERROR_PROCEDURE

(tick)

(tick)

(tick)

(tick)

Returns the name of the stored procedure or trigger where an error occurs, if that error caused the CATCH block of a TRY...CATCH construct to execute

ERROR_SEVERITY

(tick)

(tick)

(tick)

(tick)

Returns severity value of the error where an error occurs, if that error caused the CATCH block of a TRY...CATCH construct to execute

ERROR_STATE

(tick)

(tick)

(tick)

(tick)

Returns the state number of the error that caused the CATCH block of a TRY...CATCH construct to be run

EVENTDATA

(tick)

(tick)

(tick)

(tick)

Returns information about server or database events

EXP

(tick)

(tick)

(tick)

(tick)

Returns the exponential value of the specified float expression

FILEGROUPPROPERTY

(tick)

(tick)

(tick)

(tick)

Returns the filegroup property value for a specified name and filegroup value

FILEGROUP_ID

(tick)

(tick)

(tick)

(tick)

Returns the filegroup identification (ID) number for a specified filegroup name

FILEGROUP_NAME

(tick)

(tick)

(tick)

(tick)

Returns the filegroup name for the specified filegroup identification (ID) number

FILEPROPERTY

(tick)

(tick)

(tick)

(tick)

Returns the specified file name property value when a file name in the current database and a property name are specified

FILEPROPERTYEX

(minus)

(minus)

(tick)

(tick)

Returns the specified extended file property value when a file name in the current database and a property name are specified

FILE_ID

(tick)

(tick)

(tick)

(tick)

For the given logical name for a component file of the current database, this function returns the file identification (ID) number

FILE_IDEX

(tick)

(tick)

(tick)

(tick)

Returns the file identification (ID) number for the specified logical name of a data, log, or full-text file of the current database

FILE_NAME

(tick)

(tick)

(tick)

(tick)

Returns the logical file name for a given file identification (ID) number, in the context of the current database

FIRST_VALUE

(tick)

(tick)

(tick)

(tick)

Returns the first value in an ordered set of values

FLOOR

(tick)

(tick)

(tick)

(tick)

Returns the largest integer less than or equal to the specified numeric expression

FORMAT

(tick)

(tick)

(tick)

(tick)

Returns a value formatted with the specified format and optional culture. Use the FORMAT function for locale-aware formatting of date/time and number values as strings. For general data type conversions, use CAST or CONVERT

FORMATMESSAGE

(tick)

(tick)

(tick)

(tick)

Constructs a message from an existing message in sys.messages or from a provided string

FULLTEXTCATALOGPROPERTY

(tick)

(tick)

(tick)

(tick)

Returns information about full-text catalog properties in SQL Server

FULLTEXTSERVICEPROPERTY

(tick)

(tick)

(tick)

(tick)

Returns information related to the properties of the Full-Text Engine

GETANSINULL

(tick)

(tick)

(tick)

(tick)

Returns the default nullability for the database for this session

GETDATE

(tick)

(tick)

(tick)

(tick)

Returns the current database system timestamp as a datetime value without the database time zone offset. This value is derived from the operating system of the computer on which the instance of SQL Server is running

GETUTCDATE

(tick)

(tick)

(tick)

(tick)

Returns the current database system timestamp as a datetime value. The database time zone offset is not included. This value represents the current UTC time (Coordinated Universal Time). This value is derived from the operating system of the computer on which the instance of SQL Server is running

GET_BIT

(minus)

(minus)

(minus)

(tick)

Takes two parameters and returns the bit in expression_value that is in the offset defined by bit_offset

GET_FILESTREAM_TRANSACTION_CONTEXT

(tick)

(tick)

(tick)

(tick)

Returns a token that represents the current transaction context of a session. The token is used by an application to bind FILESTREAM file-system streaming operations to the transaction

GRAPH_ID_FROM_EDGE_ID

(minus)

(tick)

(tick)

(tick)

Returns the internal graph ID for a given edge ID

GRAPH_ID_FROM_NODE_ID

(minus)

(tick)

(tick)

(tick)

Returns the internal graph ID for a given node ID

GREATEST

(minus)

(minus)

(minus)

(tick)

This function returns the maximum value from a list of one or more expressions

GROUPING

(tick)

(tick)

(tick)

(tick)

Indicates whether a specified column expression in a GROUP BY list is aggregated or not

GROUPING_ID

(tick)

(tick)

(tick)

(tick)

Computes the level of grouping for multiple columns

HASHBYTES

(tick)

(tick)

(tick)

(tick)

Returns the MD2, MD4, MD5, SHA, SHA1, or SHA2 hash of its input

HAS_DBACCESS

(tick)

(tick)

(tick)

(tick)

Returns information about whether the user has access to the specified database

HAS_PERMS_BY_NAME

(tick)

(tick)

(tick)

(tick)

Evaluates the effective permission of the current user on a securable

HOST_ID

(tick)

(tick)

(tick)

(tick)

Returns the workstation identification number. The workstation identification number is the process ID (PID) of the application on the client computer that is connecting to SQL Server

HOST_NAME

(minus)

(tick)

(tick)

(tick)

Returns the workstation name

IDENTITY

(tick)

(tick)

(tick)

(tick)

Used only in a SELECT statement with an INTO table clause to insert an identity column into a new table

IDENT_CURRENT

(tick)

(tick)

(tick)

(tick)

Returns the last identity value generated for a specified table or view. The last identity value generated can be for any session and any scope

IDENT_INCR

(tick)

(tick)

(tick)

(tick)

Returns the increment value specified when creating a table or view's identity column

IDENT_SEED

(tick)

(tick)

(tick)

(tick)

Returns the original seed value specified when creating an identity column in a table or a view

IIF

(tick)

(tick)

(tick)

(tick)

Returns one of two values, depending on whether the Boolean expression evaluates to true or false

INDEXKEY_PROPERTY

(tick)

(tick)

(tick)

(tick)

Returns information about the index key

INDEXPROPERTY

(tick)

(tick)

(tick)

(tick)

Returns the named index or statistics property value of a specified table identification number, index or statistics name, and property name

INDEX_COL

(tick)

(tick)

(tick)

(tick)

Returns the indexed column name

ISDATE

(tick)

(tick)

(tick)

(tick)

Returns 1 if the expression is a valid datetime value; otherwise, 0

ISJSON

(minus)

(tick)

(tick)

(tick)

Tests whether a string contains valid JSON

ISNULL

(tick)

(tick)

(tick)

(tick)

Replaces NULL with the specified replacement value

ISNUMERIC

(tick)

(tick)

(tick)

(tick)

Determines whether an expression is a valid numeric type

IS_MEMBER

(tick)

(tick)

(tick)

(tick)

Indicates whether the current user is a member of the specified Microsoft Windows group, Microsoft Entra group, or SQL Server database role

IS_OBJECTSIGNED

(tick)

(tick)

(tick)

(tick)

Indicates whether an object is signed by a specified certificate or asymmetric key

(tick)

(tick)

(tick)

(tick)

Indicates whether a specified database principal is a member of the specified database role

IS_SRVROLEMEMBER

(tick)

(tick)

(tick)

(tick)

Indicates whether a SQL Server login is a member of the specified server role

JSON_ARRAY

(minus)

(minus)

(minus)

(tick)

Constructs JSON array text from zero or more expressions

JSON_MODIFY

(minus)

(tick)

(tick)

(tick)

Updates the value of a property in a JSON string and returns the updated JSON string

JSON_OBJECT

(minus)

(minus)

(minus)

(tick)

Constructs JSON object text from zero or more expressions

JSON_PATH_EXISTS

(minus)

(minus)

(minus)

(tick)

Tests whether a specified SQL/JSON path exists in the input JSON string

JSON_QUERY

(minus)

(tick)

(tick)

(tick)

Extracts an object or an array from a JSON string

JSON_VALUE

(minus)

(tick)

(tick)

(tick)

Extracts a scalar value from a JSON string

KEY_GUID

(tick)

(tick)

(tick)

(tick)

Returns the GUID of a symmetric key in the database

KEY_ID

(tick)

(tick)

(tick)

(tick)

Returns the ID of a symmetric key in the current database

KEY_NAME

(tick)

(tick)

(tick)

(tick)

Returns the name of the symmetric key from either a symmetric key GUID or cipher text

LAG

(tick)

(tick)

(tick)

(tick)

Accesses data from a previous row in the same result set without the use of a self-join in order to compare values in the current row with values in a previous row

LAST_VALUE

(tick)

(tick)

(tick)

(tick)

Returns the last value in an ordered set of values

LEAD

(tick)

(tick)

(tick)

(tick)

Accesses data from a subsequent row in the same result set without the use of a self-join in order to compare values in the current row with values in a following row

LEAST

(minus)

(minus)

(minus)

(tick)

This function returns the minimum value from a list of one or more expressions

LEFT

(tick)

(tick)

(tick)

(tick)

Returns the left part of a character string with the specified number of characters

LEFT_SHIFT

(minus)

(minus)

(minus)

(tick)

Takes two parameters, and returns the first parameter bit-shifted left by the number of bits specified in the second parameter

LEN

(tick)

(tick)

(tick)

(tick)

Returns the number of characters of the specified string expression, excluding trailing spaces

LOG

(tick)

(tick)

(tick)

(tick)

Returns the natural logarithm of the specified float expression

LOG10

(tick)

(tick)

(tick)

(tick)

Returns the base-10 logarithm of the specified float expression

LOGINPROPERTY

(tick)

(tick)

(tick)

(tick)

Returns information about login policy settings

LOWER

(tick)

(tick)

(tick)

(tick)

Returns a character expression after converting uppercase character data to lowercase

LTRIM

(tick)

(tick)

(tick)

(tick)

Removes space character char(32) or other specified characters from the start of a string

MAX

(tick)

(tick)

(tick)

(tick)

Returns the maximum value in the expression

MIN

(tick)

(tick)

(tick)

(tick)

Returns the minimum value in the expression

MIN_ACTIVE_ROWVERSION

(tick)

(tick)

(tick)

(tick)

Returns the lowest active rowversion value in the current database. A rowversion value is active if it is used in a transaction that has not yet been committed

MONTH

(tick)

(tick)

(tick)

(tick)

Returns an integer that represents the month of the specified date

NCHAR

(tick)

(tick)

(tick)

(tick)

Returns the Unicode character with the specified integer code, as defined by the Unicode standard

NEWID

(tick)

(tick)

(tick)

(tick)

Creates a unique value of type uniqueidentifier

NEWSEQUENTIALID

(tick)

(tick)

(tick)

(tick)

Creates a GUID that is greater than any GUID previously generated by this function on a specified computer since Windows was started

NODE_ID_FROM_PARTS

(minus)

(tick)

(tick)

(tick)

Returns the character representation (JSON) of the node ID for a given object ID and graph ID

NTILE

(tick)

(tick)

(tick)

(tick)

Distributes the rows in an ordered partition into a specified number of groups. The groups are numbered, starting at one. For each row, NTILE returns the number of the group to which the row belongs

OBJECTPROPERTY

(tick)

(tick)

(tick)

(tick)

Returns information about schema-scoped objects in the current database

OBJECTPROPERTYEX

(tick)

(tick)

(tick)

(tick)

Returns information about schema-scoped objects in the current database

OBJECT_DEFINITION

(tick)

(tick)

(tick)

(tick)

Returns the Transact-SQL source text of the definition of a specified object

OBJECT_ID

(tick)

(tick)

(tick)

(tick)

Returns the database object identification number of a schema-scoped object

OBJECT_ID_FROM_EDGE_ID

(minus)

(tick)

(tick)

(tick)

Returns the object ID for a given graph edge ID

OBJECT_ID_FROM_NODE_ID

(minus)

(tick)

(tick)

(tick)

Returns the object ID for a given graph node ID

OBJECT_NAME

(tick)

(tick)

(tick)

(tick)

Returns the database object name for schema-scoped objects

OBJECT_SCHEMA_NAME

(tick)

(tick)

(tick)

(tick)

Returns the database schema name for schema-scoped objects

ORIGINAL_DB_NAME

(tick)

(tick)

(tick)

(tick)

Returns the database name specified by the user in the database connection string

ORIGINAL_LOGIN

(tick)

(tick)

(tick)

(tick)

Returns the name of the login that connected to the instance of SQL Server

PARSE

(tick)

(tick)

(tick)

(tick)

Returns the result of an expression, translated to the requested data type

PARSENAME

(tick)

(tick)

(tick)

(tick)

Returns the specified part of an object name. The parts of an object that can be retrieved are the object name, schema name, database name, and server name

PATINDEX

(tick)

(tick)

(tick)

(tick)

Returns the starting position of the first occurrence of a pattern in a specified expression, or zero if the pattern is not found

PERCENTILE_CONT

(tick)

(tick)

(tick)

(tick)

Calculates a percentile based on a continuous distribution of the column value

PERCENTILE_DISC

(tick)

(tick)

(tick)

(tick)

Computes a specific percentile for sorted values in an entire rowset or within a rowsets distinct partitions

PERCENT_RANK

(tick)

(tick)

(tick)

(tick)

Calculates the relative rank of a row within a group of rows

PERMISSIONS

(tick)

(tick)

(tick)

(tick)

Returns a value containing a bitmap that indicates the statement, object, or column permissions of the current user

PI

(tick)

(tick)

(tick)

(tick)

Returns the constant value of PI

POWER

(tick)

(tick)

(tick)

(tick)

Returns the value of the specified expression to the specified power

PUBLISHINGSERVERNAME

(tick)

(tick)

(tick)

(tick)

Returns the name of the originating Publisher for a published database participating in a database mirroring session

PWDCOMPARE

(tick)

(tick)

(tick)

(tick)

Hashes a password and compares the hash to the hash of an existing password

PWDENCRYPT

(tick)

(tick)

(tick)

(tick)

Returns the SQL Server password hash of the input value that uses the current version of the password hashing algorithm

QUOTENAME

(tick)

(tick)

(tick)

(tick)

Returns a Unicode string with the delimiters added to make the input string a valid SQL Server delimited identifier

RADIANS

(tick)

(tick)

(tick)

(tick)

Returns radians when a numeric expression, in degrees, is entered

RAND

(tick)

(tick)

(tick)

(tick)

Returns a pseudo-random float value from 0 through 1, exclusive

RANK

(tick)

(tick)

(tick)

(tick)

Returns the rank of each row within the partition of a result set

REPLACE

(tick)

(tick)

(tick)

(tick)

Replaces all occurrences of a specified string value with another string value

REPLICATE

(tick)

(tick)

(tick)

(tick)

Repeats a string value a specified number of times

REVERSE

(tick)

(tick)

(tick)

(tick)

Returns the reverse order of a string value

RIGHT

(tick)

(tick)

(tick)

(tick)

Returns the right part of a character string with the specified number of characters

RIGHT_SHIFT

(minus)

(minus)

(minus)

(tick)

Takes two parameters, and returns the first parameter bit-shifted right by the number of bits specified in the second parameter

ROUND

(tick)

(tick)

(tick)

(tick)

Returns a numeric value, rounded to the specified length or precision

ROWCOUNT_BIG

(tick)

(tick)

(tick)

(tick)

Returns the number of rows affected by the last statement executed. This function operates like @@ROWCOUNT, except the return type of ROWCOUNT_BIG is bigint

ROW_NUMBER

(tick)

(tick)

(tick)

(tick)

Returns the sequential number of a row within a partition of a result set, starting at 1 for the first row in each partition

RTRIM

(tick)

(tick)

(tick)

(tick)

Removes space character char(32) or other specified characters from the end of a string

SCHEMA_ID

(tick)

(tick)

(tick)

(tick)

Returns the schema ID associated with a schema name

SCHEMA_NAME

(tick)

(tick)

(tick)

(tick)

Returns the schema name associated with a schema ID

SERVERPROPERTY

(tick)

(tick)

(tick)

(tick)

Returns property information about the server instance

SESSIONPROPERTY

(tick)

(tick)

(tick)

(tick)

Returns the SET options settings of a session

SESSION_CONTEXT

(minus)

(tick)

(tick)

(tick)

Returns the value of the specified key in the current session context. The value is set by using the sp_set_session_context (Transact-SQL) procedure

SESSION_USER

(tick)

(tick)

(tick)

(tick)

Returns the user name of the current context in the current database

SET_BIT

(minus)

(minus)

(minus)

(tick)

Returns expression_value offset by the bit defined by bit_offset. The bit value defaults to 1, or is set by bit_value

SIGN

(tick)

(tick)

(tick)

(tick)

Returns the positive (+1), zero (0), or negative (-1) sign of the specified expression

SIGNBYASYMKEY

(tick)

(tick)

(tick)

(tick)

Signs plaintext with an asymmetric key

SIGNBYCERT

(tick)

(tick)

(tick)

(tick)

Signs text with a certificate and returns the signature

SIN

(tick)

(tick)

(tick)

(tick)

Returns the trigonometric sine of the specified angle, in radians

SMALLDATETIMEFROMPARTS

(tick)

(tick)

(tick)

(tick)

Returns a smalldatetime value for the specified date and time

SOUNDEX

(tick)

(tick)

(tick)

(tick)

Returns a four-character (SOUNDEX) code that is based on how the string sounds when spoken in English to evaluate the similarity of two strings

SPACE

(tick)

(tick)

(tick)

(tick)

Returns a string of repeated spaces

SQL_VARIANT_PROPERTY

(tick)

(tick)

(tick)

(tick)

Returns the base data type and other information about a sql_variant value

SQRT

(tick)

(tick)

(tick)

(tick)

Returns the square root of the specified float value

SQUARE

(tick)

(tick)

(tick)

(tick)

Returns the square of the specified float value

STATS_DATE

(tick)

(tick)

(tick)

(tick)

Returns the date of the most recent update for statistics on a table or indexed view

STDEV

(tick)

(tick)

(tick)

(tick)

Returns the statistical standard deviation of all values in the specified expression

STDEVP

(tick)

(tick)

(tick)

(tick)

Returns the statistical standard deviation for the population for all values in the specified expression

STR

(tick)

(tick)

(tick)

(tick)

Returns character data converted from numeric data. The character data is right-justified, with a specified length and decimal precision

STRING_AGG

(minus)

(tick)

(tick)

(tick)

Concatenates the values of string expressions and places separator values between them. The separator isn't added at the end of string

STRING_ESCAPE

(minus)

(tick)

(tick)

(tick)

Escapes special characters in texts and returns text with escaped characters

STUFF

(tick)

(tick)

(tick)

(tick)

Inserts a string into another string. It deletes a specified length of characters in the first string at the start position and then inserts the second string into the first string at the start position

SUBSTRING

(tick)

(tick)

(tick)

(tick)

Returns part of a character, binary, text, or image expression in SQL Server

SUM

(tick)

(tick)

(tick)

(tick)

Returns the sum of all the values, or only the DISTINCT values, in the expression

SUSER_ID

(tick)

(tick)

(tick)

(tick)

Returns the login identification number of the user

SUSER_NAME

(tick)

(tick)

(tick)

(tick)

Returns the login identification name of the user

SUSER_SID

(tick)

(tick)

(tick)

(tick)

Returns the security identification number (SID) for the specified login name

SUSER_SNAME

(tick)

(tick)

(tick)

(tick)

Returns the login name associated with a security identification number (SID)

SWITCHOFFSET

(tick)

(tick)

(tick)

(tick)

Returns a datetimeoffset value that is changed from the stored time zone offset to a specified new time zone offset

SYMKEYPROPERTY

(tick)

(tick)

(tick)

(tick)

Returns the algorithm of a symmetric key created from an EKM module

SYSDATETIME

(tick)

(tick)

(tick)

(tick)

Returns a datetime2(7) value that contains the date and time of the computer on which the instance of SQL Server is running

SYSDATETIMEOFFSET

(tick)

(tick)

(tick)

(tick)

Returns a datetimeoffset(7) value that contains the date and time of the computer on which the instance of SQL Server is running. The time zone offset is included

SYSTEM_USER

(tick)

(tick)

(tick)

(tick)

Allows a system-supplied value for the current login to be inserted into a table when no default value is specified

SYSUTCDATETIME

(tick)

(tick)

(tick)

(tick)

Returns a datetime2 value that contains the date and time of the computer on which the instance of SQL Server is running. The date and time is returned as UTC time (Coordinated Universal Time). The fractional second precision specification has a range from 1 to 7 digits. The default precision is 7 digits

TAN

(tick)

(tick)

(tick)

(tick)

Returns the tangent of the input expression

TERTIARY_WEIGHTS

(tick)

(tick)

(tick)

(tick)

For each character in a non-Unicode string expression - defined with a SQL tertiary collation - this function returns a binary string of weights

TEXTPTR

(tick)

(tick)

(tick)

(tick)

Returns the text-pointer value that corresponds to a text, ntext, or image column in varbinary format. The retrieved text pointer value can be used in READTEXT, WRITETEXT, and UPDATETEXT statements

TEXTVALID

(tick)

(tick)

(tick)

(tick)

A text, ntext, or image function that checks whether a specific text pointer is valid

TIMEFROMPARTS

(tick)

(tick)

(tick)

(tick)

Returns a time value for the specified time and with the specified precision

TODATETIMEOFFSET

(tick)

(tick)

(tick)

(tick)

Returns a datetimeoffset value that is translated from a datetime2 expression

TRANSLATE

(minus)

(tick)

(tick)

(tick)

Returns the string provided as a first argument, after some characters specified in the second argument are translated into a destination set of characters, specified in the third argument

TRIGGER_NESTLEVEL

(tick)

(tick)

(tick)

(tick)

Returns the number of triggers executed for the statement that fired the trigger

TRY_CAST

(tick)

(tick)

(tick)

(tick)

Returns a value cast to the specified data type if the cast succeeds otherwise, returns NULL

TRY_CONVERT

(tick)

(tick)

(tick)

(tick)

Returns a value cast to the specified data type if the cast succeeds otherwise, returns NULL

TRY_PARSE

(tick)

(tick)

(tick)

(tick)

Returns the result of an expression, translated to the requested data type, or null if the cast fails

TYPEPROPERTY

(tick)

(tick)

(tick)

(tick)

Returns information about a data type

TYPE_ID

(tick)

(tick)

(tick)

(tick)

Returns the ID for a specified data type name

TYPE_NAME

(tick)

(tick)

(tick)

(tick)

Returns the unqualified type name of a specified type ID

UNICODE

(tick)

(tick)

(tick)

(tick)

Returns the integer value, as defined by the Unicode standard, for the first character of the input expression

UPDATE

(tick)

(tick)

(tick)

(tick)

Returns a Boolean value that indicates whether an INSERT or UPDATE attempt was made on a specified column of a table or view

UPPER

(tick)

(tick)

(tick)

(tick)

Returns a character expression with lowercase character data converted to uppercase

USER

(tick)

(tick)

(tick)

(tick)

Allows a system-supplied value for the current login to be inserted into a table when no default value is specified

USER_ID

(tick)

(tick)

(tick)

(tick)

Returns the identification number for a database user

USER_NAME

(tick)

(tick)

(tick)

(tick)

Returns a database user name from a specified identification number, or the current user name

VAR

(tick)

(tick)

(tick)

(tick)

Returns the statistical variance of all values in the specified expression

VARP

(tick)

(tick)

(tick)

(tick)

Returns the statistical variance for the population for all values in the specified expression

VERIFYSIGNEDBYASYMKEY

(tick)

(tick)

(tick)

(tick)

Tests whether digitally signed data has been changed since it was signed

VERIFYSIGNEDBYCERT

(tick)

(tick)

(tick)

(tick)

Tests whether digitally signed data has been changed since it was signed

XACT_STATE

(tick)

(tick)

(tick)

(tick)

Returns whether the request has an active user transaction, and whether the transaction is capable of being committed

YEAR

(tick)

(tick)

(tick)

(tick)

Returns an integer that represents the year of the specified date

JavaScript errors detected

Please note, these errors can depend on your browser setup.

If this problem persists, please contact our support.