title | description | author | ms.author | ms.date | ms.service | ms.subservice | ms.topic | f1_keywords | helpviewer_keywords | dev_langs | ||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
@@MAX_CONNECTIONS (Transact-SQL) |
@@MAX_CONNECTIONS (Transact-SQL) |
markingmyname |
maghan |
09/18/2017 |
sql |
t-sql |
reference |
|
|
|
[!INCLUDE SQL Server Azure SQL Managed Instance]
Returns the maximum number of simultaneous user connections allowed on an instance of [!INCLUDEssNoVersion]. The number returned is not necessarily the number currently configured.
:::image type="icon" source="../../includes/media/topic-link-icon.svg" border="false"::: Transact-SQL syntax conventions
@@MAX_CONNECTIONS
integer
The actual number of user connections allowed also depends on the version of [!INCLUDEssNoVersion] that is installed and the limitations of your applications and hardware.
To reconfigure [!INCLUDEssNoVersion] for fewer connections, use sp_configure.
The following example shows returning the maximum number of user connections on an instance of [!INCLUDEssNoVersion]. The example assumes that [!INCLUDEssNoVersion] has not been reconfigured for fewer user connections.
SELECT @@MAX_CONNECTIONS AS 'Max Connections';
[!INCLUDEssResult]
Max Connections
---------------
32767
sp_configure
Configuration Functions
Configure the user connections Server Configuration Option