SQL Server 2016 new features: database-level configuration

Source: Internet
Author: User

The new ALTER Database SCOPED configuration (Transact-SQL) is used to configure the database-level configuration. This statement can configure the configuration of each database:
    • Cleanup process Cache
    • Set the MAXDOP parameter to configure primary and secondary
    • Set the evaluation mode for the query optimizer
    • Starting and shutting down database-level parameter sniffing
    • Start and close database-level query optimization patches
    • To start and close the identity cache at the database level
Syntax:ALTER DATABASE SCOPED CONFIGURATION {{[for secondary] SET <set_options>}} | CLEAR Procedure_cache |    SET < set_options >[;] < Set_options >:: = {MAXDOP = {<value> | | PRIMARY} | Legacy_cardinality_estimation = {on | OFF | PRIMARY} | parameter_sniffing = {on | OFF | PRIMARY} | query_optimizer_hotfixes = {on | OFF | PRIMARY} | Identity_cache = {on | OFF}} Parameters:For secondary specifies the database to set secondary MAXDOP = {<value> | PRIMARY} set MAXDOP, the default is 0, if you set the database execution will overwrite the configuration in sp_configure, if there are query hints, query hints will overwrite this configuration. Primary means that if primary is set on secondary, then secondary integrates the settings on the primary. Legacy_cardinality_estimation = {on | OFF | PRIMARY} allows you to set the query optimizer evaluation mode if off will use the query optimizer evaluation mode based on compatibility level if the old query optimizer is used for on. Primary is the same as above parameter_sniffing = {on | OFF | PRIMARY} startup and shutdown parameters sniffer query_optimizer_hotfixes = {on | OFF | PRIMARY} starts and closes the query optimization patch, regardless of the database compatibility level. The default is off, turn off query optimization patches, and see Microsoft Support article for patches specifically. The clear Procedure_cache cleanup process schedule can be executed in primary,secondary. Identity_cache = {on | Off} to start and close the identity cache at the database level. By default, the On,identity cache is used to improve the performance of insert in identity. To avoid an identity gap, you can choose to close.

SQL Server 2016 new features: database-level configuration

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.