| title | @@VERSION (Transact-SQL) | ||||
|---|---|---|---|---|---|
| description | @@VERSION - Transact SQL Configuration Functions | ||||
| author | MikeRayMSFT | ||||
| ms.author | mikeray | ||||
| ms.reviewer | maghan | ||||
| ms.date | 09/25/2024 | ||||
| ms.service | sql | ||||
| ms.subservice | t-sql | ||||
| ms.topic | reference | ||||
| f1_keywords |
|
||||
| helpviewer_keywords |
|
||||
| dev_langs |
|
||||
| monikerRange | >=aps-pdw-2016||=azuresqldb-current||=azure-sqldw-latest||>=sql-server-2016||>=sql-server-linux-2017||=azuresqldb-mi-current||=fabric |
[!INCLUDE sql-asdb-asdbmi-asa-pdw-fabricse-fabricdw-fabricsqldb]
Returns system and build information for the current installation of [!INCLUDE ssNoVersion].
:::image type="icon" source="../../includes/media/topic-link-icon.svg" border="false"::: Transact-SQL syntax conventions
Important
The [!INCLUDE ssDE-md] version numbers for [!INCLUDE ssNoVersion] and [!INCLUDE ssazure-sqldb] are not comparable with each other, and represent internal build numbers for these separate products. The [!INCLUDE ssDE-md] for [!INCLUDE ssazure-sqldb] is based on the same code base as the [!INCLUDE ssDEnoversion]. Most importantly, the [!INCLUDE ssDE-md] in [!INCLUDE ssazure-sqldb] always has the newest SQL [!INCLUDE ssDE-md] bits. For example, version 12 of [!INCLUDE ssazure-sqldb] is newer than version 16 of [!INCLUDE ssNoVersion].
@@VERSION
nvarchar
The @@VERSION results are presented as one nvarchar string. You can use the SERVERPROPERTY (Transact-SQL) function to retrieve the individual property values.
For [!INCLUDE ssNoVersion], the following information is returned.
-
[!INCLUDE ssNoVersion] version
-
Processor architecture
-
[!INCLUDE ssNoVersion] build date
-
Copyright statement
-
[!INCLUDE ssNoVersion] edition
-
Operating system version
For [!INCLUDE ssazure-sqldb] and [!INCLUDE ssazuremi-md], the following information is returned.
-
Edition- "Microsoft SQL Azure"
-
Product level- "(RTM)"
-
Product version
-
Build date
-
Copyright statement
A: Return the current version of [!INCLUDE ssNoVersion]
The following example shows returning the version information for the current installation.
SELECT @@VERSION AS 'SQL Server Version';Examples: [!INCLUDE ssazuresynapse-md] and [!INCLUDE ssPDW]
B. Return the current version of [!INCLUDE ssazuresynapse-md]
SELECT @@VERSION AS 'SQL Server PDW Version';