SQL sets the maximum number of SQLServer connections

Source: Internet
Author: User
Set the T-SQL statement under the maximum number of connections to configure the maximum number of concurrent user connections allowed by SQLServer. No execsp_configureshowadvancedoptions, 1execsp_configureuserconnections, the first sentence of 100 is used to show the advanced options of sp_configure system stored procedure, using userconnectio

Set the T-SQL statement under the maximum number of connections to configure the maximum number of concurrent user connections allowed by SQL Server. No exec sp_configure 'show advanced options', 1 exec sp_configure 'user connections', the first sentence of 100 is used to show the advanced options of sp_configure system stored procedure, using user connectio

Set the maximum number of connections

The following T-SQL statements configure the maximum number of concurrent user connections allowed by SQL Server. <无>
Exec sp_configure 'show advanced options', 1 exec sp_configure 'user connections', the first sentence of 100 is used to display the advanced options of the sp_configure system stored procedure. When user connections is used, the value of show advanced options must be 1. In the second sentence, the maximum number of connections is. 0 indicates no limit, but not unlimited. You can also configure it in Enterprise Manager. In Enterprise Manager, you can right-click an instance and choose "properties"> "connection" to change it. You need to restart SQL Server to make the value take effect. @ Max_connections select @ max_connections it always returns 32767. It does not indicate the user connections set above, but actually the maximum number of user connections values that can be set. Since the maximum value is 32767, when user connections is 0, the maximum number of connections is 32767, which is not infinite. By default, the user connections value is 0, which means that the maximum number of connections of SQL Server is 32767 by default. Obtain the maximum number of connections currently set: select value from master. dbo. sysconfigures where [config] = 103

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.