Cumulative Update 15 for SQL Server 2017

Applies to: SQL Server 2017 on Windows (all editions)SQL Server 2017 on Linux (all editions)

This article describes Cumulative Update package 15 (CU15) for SQL Server 2017. This update contains fixes that were released after the initial release of SQL Server 2017 and updates the SQL Server and Analysis services components to the following builds:

Component Build version File version
SQL Server 14.0.3162.1 2017.140.3162.1
Analysis Services 2017.140.249.3


Important notices

This article also provides important information about the following situations:

  • Pacemaker: A behavioral change is made in distributions that use the latest available version of Pacemaker. Mitigations methods are provided.
  • Query Store: You must run this script if you use Query Store and you have previously installed SQL Server 2017 Cumulative Update 2 (CU2).
  • Availability Group preferred replica backups: An error occurs if you use sys.fn_hadr_backup_is_preferred_replica to determine the preferred Availability Group replica for backup jobs. 
  • Analysis Services CU build version: Beginning in SQL Server 2017, the Analysis Services build version number and SQL Server Database Engine build version number do not match. For more information, see Verify Analysis Services cumulative update build version.

Cumulative updates

Cumulative updates (CU) are now available at the Microsoft Download Center.

Only the most recent CU that was released for SQL Server 2017 is available at the Download Center.

CU packages for Linux are available at


  • Each new CU contains all the fixes that were included with the previous CU for the installed version of SQL Server.
  • SQL Server CUs are certified to the same levels as Service Packs, and should be installed at the same level of confidence.
  • Microsoft recommends ongoing, proactive installation of CUs as they become available according to these guidelines:
    • Historical data shows that a significant number of support cases involve an issue that has already been addressed in a released CU.
    • CUs may contain added value over and above hotfixes. This includes supportability, manageability, and reliability updates.
  • We recommend that you test CUs before you deploy them to production environments.

How to obtain this cumulative update package for Windows

The following update is available from the Microsoft Download Center:

If the download page does not appear, contact Microsoft Customer Service and Support to obtain the cumulative update package.


  • After future cumulative updates are released for SQL Server 2017, this and all previous CUs can be downloaded from the Microsoft Update Catalog. However, we recommend that you always install the latest cumulative update that is available.

How to obtain this cumulative update package for Linux

To update Linux to the latest CU, you must first have the Cumulative Update repository configured. Then, update your SQL Server packages by using the appropriate platform-specific update command.

For installation instructions and direct links to the CU package downloads, see the release notes.

Additional hotfixes that are included in this cumulative update package

VSTS bug number KB article number Description Fix area Platform
12750851 4480652 FIX: SQL Writer Service can cause undetected deadlocks on system DMV when you do a VSS backup SQL Engine Windows
12819465 4488853 FIX: 'MSrepl_agent_jobs' does not exist when you run sp_addpullsubscription_agent to create pull subscription in SQL Server 2016 and 2017 SQL Engine Windows
12819467 4489202 FIX: Error 10314 occurs when you load .NET CLR assembly in SQL Server 2016 and 2017 database SQL Engine Windows
12674647 4490136 FIX: Assertion error occurs when you use sys.dm_exec_query_statistics_xml in SQL Server 2016 and 2017 SQL performance Windows
12819460 4490141 Improvement: DMV sys.dm_hadr_cluster reports cloud witness quorum type "4" and quorum_type_desc "UNKNOWN_QUORUM" in SQL Server 2016 and 2017 High Availability Windows
12723965 4490237 FIX: Restoring backup to SQL Server 2016 and 2017 from SQL Server 2008 or 2008 R2 takes a long time SQL Engine Windows
12700741 4490478 FIX: AD authentication fails to connect to SQL Server 2017 SQL Engine Linux
12640919 4492604 FIX: Manual failover between forwarder and secondary replica fails with all replicas synchronized in SQL Server 2016 and 2017 High Availability Windows
12819475 4492880 FIX: Automatic seeding assertions occur when databases are removed from AG in SQL Server 2016 and 2017 High Availability Windows
12819479 4492899 FIX: FileTable database level directory is inaccessible after database startup in SQL Server 2016 and 2017 SQL Engine Windows
12644521 4493329 FIX: Error occurs when sp_addarticle is used to add article for transactional replication to memory-optimized table on subscriber in SQL Server 2016 and 2017 SQL Engine Windows
12819478 4493363 FIX: A specially crafted query run by a low privileged user may expose the masked data in SQL Server 2016 and 2017 SQL security Windows
12931699 4493364 FIX: Error occurs when you back up a virtual machine with non-component based backup in SQL Server 2016 and 2017 SQL Engine Windows
12794414 4494650 FIX: Access violation occurs when you run a batch-mode query with UNION statement in SQL Server 2017 SQL performance Windows
12804071 4495683 FIX: Search Attribute doesn't work when display format is set to "Name {Code}" in SQL Server 2017 Data Quality Services (DQS) Windows
12840763 4497225 FIX: Query against table with both clustered columnstore index and nonclustered rowstore index may return incorrect results in SQL Server 2016 and 2017 SQL Engine All
12865861 4497230 FIX: Fail to join the secondary replica if the database has a defunct filegroup in SQL Server 2014, 2016 and 2017 High Availability Windows
12840765 4497701 FIX: Columnstore filter pushdown may return wrong results when there is an overflow in filter expressions in SQL Server 2014, 2016 and 2017 SQL Engine All
12831695 4498720 FIX: Core dump failed to generate on m_numLocks.load() == 0 error in SQL Server 2017 SQL Engine Linux
12844344 4498924 FIX: Gray background for read-only attributes disappears after Refresh in Excel Add-in for MDS in SQL Server 2017 Data Quality Services (DQS) Windows
12865874 4499231 FIX: Log reader agent may fail after AG failover with TF 1448 enabled in SQL Server 2014, 2016 and 2017 SQL Engine Windows
12670267 4499423 FIX: SSIS and Power BI reports fail with connection time-out errors in SQL Server 2017 SQL Engine Linux
12821584 4499614 FIX: Access Violation occurs due to corruption of compressed Showplan.xml file in SQL Server 2017 SQL performance Windows
12819474 4500327 FIX: Non-yielding scheduler issue occurs when you run queries in batch mode that spill in SQL Server 2016 and 2017 SQL performance Windows
12686636 4500511 Improvement: Improve CDC supportability and usability with In-Memory Databases SQL Engine All
12870721 4500574 FIX: Self-deadlock occurs when transaction auditing is enabled in SQL Server 2017 SQL security All
12710985 4500595 FIX: CDC Source preview fails with "The given key was not present in the dictionary" error in SQL Server 2017 Integration Services Windows
12789617 4500783 FIX: Interleaved execution on MSTVFs by using memory-optimized tables causes floating point exception in SQL Server 2017 In-Memory OLTP All
12886436 4501670 FIX: CPU and elapsed time reported by query_plan_profile and query_post_execuion_plan_profile xEvents are not accurate in SQL Server 2017 SQL performance All
12877988 4501797 FIX: Data movement to DAG Forwarder does not resume automatically after connection time-out in SQL Server 2016 and 2017 High Availability Windows
12799964 4502376 FIX: Access violation occurs in sqlmin!AGHealthCompStateActual::GetData in SQL Server 2017 High Availability Linux
12745415 4502380 FIX: SQL Server 2017 crashes due to stack overflow when you try to back up database master to disk SQL Engine Windows
12805642 4502400 FIX: SQL Server 2016 and 2017 do not perform the requested pre-row assignments when you use MERGE statement that performs assignments of local variables for each row SQL performance All
12816127 4502427 FIX: Access violation occurs when you run sys.fn_dump_dblog function in SQL Server 2016 and 2017 SQL Engine Windows
12768690 4502532 FIX: Query takes long time if you enable Batch Mode Adaptive Join in SQL Server 2017 SQL performance Windows
12756913 4502658 FIX: "No valid credentials provided" occurs after you restart PolyBase in SQL Server 2017 SQL Engine Windows
12820675 4502659 FIX: PolyBase queries that target Parquet or ORC files in HDP 3.0 or later will fail with pushdown computation enabled SQL Engine Windows
12798181 4502706 FIX: SQL Server generates core dump with "Failed to monitor external signals" in SQL Server 2017 SQL Engine All
12819466 4503379 FIX: Referential integrity constraints are not evaluated correctly when query execution plan uses Foreign Key Reference Check operator in SQL Server 2016 and 2017 SQL performance Windows
12823369 4503385 FIX: DAX query requires more than 200 times of memory than the size of the database in SQL Server 2017 multidimensional model database Analysis Services Windows
12745584 4503386 FIX: Exception occurs when you design a parameterized DAX query in Query Designer of Report Builder in SSRS Analysis Services Windows
12921007 4503417 FIX: Assertion dump occurs when you select a view on a linked server in SQL Server 2017 SQL performance Windows
12812315 4505726 FIX: Dynamic Data Masking does not function as expected in SQL Server 2017 SQL security Windows
12892302 4505820 FIX: SQLCLR function takes a longer time to run the query in CU 14 than RTM of SQL Server 2017 SQL performance Windows

Notes for this update

Hybrid environments deployment

When you deploy an update to a hybrid environment (such as AlwaysOn, replication, cluster, and mirroring), we recommend that you refer to the following articles before you deploy the update:

Cumulative update package information


To apply this cumulative update package, you must be running SQL Server 2017.

Restart information

You may have to restart the computer after you apply this cumulative update package.

Registry information

To use one of the hotfixes in this package, you do not have to make any changes to the registry.

More CU package information

Pacemaker notice


All distributions (including RHEL 7.3 and 7.4) that use the latest available Pacemaker package 1.1.18-11.el7 introduce a behavior change for the start-failure-is-fatal cluster setting when its value is false. This change affects the failover workflow. If a primary replica experiences an outage, the cluster is expected to failover to one of the available secondary replicas. Instead, users will notice that the cluster keeps trying to start the failed primary replica. If that primary never comes online (because of a permanent outage), the cluster never fails over to another available secondary replica.

This issue affects all SQL Server versions, regardless of the cumulative update version that they are on.

To mitigate the issue, use either of the following methods.

Method 1

Follow these steps:

  1. Remove the start-failure-is-fatal override from the existing cluster. 
       # RHEL, Ubuntu         pcs property unset start-failure-is-fatal         # or         pcs property set start-failure-is-fatal=true   # SLES         crm configure property start-failure-is-fatal=true
  2. Decrease the cluster-recheck-interval value. 
       # RHEL, Ubuntu         pcs property set cluster-recheck-interval=<Xmin>   # SLES         crm configure property cluster-recheck-interval=<Xmin>
  3. Add the failure-timeout meta property to each AG resource. 
       # RHEL, Ubuntu         pcs resource update ag1 meta failure-timeout=60s   # SLES         crm configure edit ag1      # In the text editor, add `meta failure-timeout=60s` after any `param`s and before any `op`s

    Note In this code, substitute the value for <Xmin> as appropriate. If a replica goes down, the cluster tries to restart the replica at an interval that is bound by the failure-timeout value and the cluster-recheck-interval value. For example, if failure-timeout is set to 60 seconds and cluster-recheck-interval is set to 120 seconds, the restart is tried at an interval that is greater than 60 seconds but less than 120 seconds. We recommend that you set failure-timeout to 60s and cluster-recheck-interval to a value that is greater than 60 seconds. Setting cluster-recheck-interval to a small value is not recommended. For more information, refer to the Pacemaker documentation or consult the system provider.

Method 2

Revert to Pacemaker version 1.1.16.

    Query Store notice


    You must run this script if you use Query Store and you are updating from SQL Server 2017 Cumulative Update 2 (CU2) directly to SQL Server 2017 Cumulative Update 3 (CU3) or any later Cumulative Update. Executing this script is not needed if you have previously installed SQL Server 2017 Cumulative Update 3 (CU3) or any later SQL Server 2017 Cumulative Update.


    SET NOCOUNT ON;DROP TABLE IF EXISTS #tmpUserDBs;SELECT [database_id], 0 AS [IsDone]INTO #tmpUserDBsFROM master.sys.databasesWHERE [database_id] > 4 AND [state] = 0 -- must be ONLINE AND is_read_only = 0 -- cannot be READ_ONLY AND [database_id] NOT IN (SELECT dr.database_id FROM sys.dm_hadr_database_replica_states dr -- Except all local Always On secondary replicas  INNER JOIN sys.dm_hadr_availability_replica_states rs ON dr.group_id = rs.group_id  INNER JOIN sys.databases d ON dr.database_id = d.database_id  WHERE rs.role = 2 -- Is Secondary   AND dr.is_local = 1   AND rs.is_local = 1)DECLARE @userDB sysname;WHILE (SELECT COUNT([database_id]) FROM #tmpUserDBs WHERE [IsDone] = 0) > 0BEGIN SELECT TOP 1 @userDB = DB_NAME([database_id]) FROM #tmpUserDBs WHERE [IsDone] = 0 -- PRINT 'Working on database ' + @userDB EXEC ('USE [' + @userDB + '];DECLARE @clearPlan bigint, @clearQry bigint;IF EXISTS (SELECT [actual_state] FROM sys.database_query_store_options WHERE [actual_state] IN (1,2))BEGIN IF EXISTS (SELECT plan_id FROM sys.query_store_plan WHERE engine_version = ''14.0.3008.27'') BEGIN  DROP TABLE IF EXISTS #tmpclearPlans;  SELECT plan_id, query_id, 0 AS [IsDone]  INTO #tmpclearPlans  FROM sys.query_store_plan WHERE engine_version = ''14.0.3008.27''  WHILE (SELECT COUNT(plan_id) FROM #tmpclearPlans WHERE [IsDone] = 0) > 0  BEGIN   SELECT TOP 1 @clearPlan = plan_id, @clearQry = query_id FROM #tmpclearPlans WHERE [IsDone] = 0   EXECUTE sys.sp_query_store_unforce_plan @clearQry, @clearPlan;   EXECUTE sys.sp_query_store_remove_plan @clearPlan;   UPDATE #tmpclearPlans   SET [IsDone] = 1   WHERE plan_id = @clearPlan AND query_id = @clearQry  END;  PRINT ''- Cleared possibly affected plans in database [' + @userDB + ']'' END ELSE BEGIN  PRINT ''- No affected plans in database [' + @userDB + ']'' ENDENDELSEBEGIN PRINT ''- Query Store not enabled in database [' + @userDB + ']''END')  UPDATE #tmpUserDBs  SET [IsDone] = 1  WHERE [database_id] = DB_ID(@userDB)END

    Availability Group preferred replica backups


    Consider the following scenario:

    • You are running an Availability Group on a Windows Server failover cluster.
    • You are using the sys.fn_hadr_backup_is_preferred_replica function within your backup jobs to determine whether to run a backup on the current replica.

    In this scenario, the function call fails and generates the following error message: 

    This issue does not affect the backup itself. Therefore, you can work around this issue by removing the call to sys.fn_hadr_backup_is_preferred_replica.

    If you have to back up only on the preferred replica, we recommended that you do not apply Cumulative Update 15. This issue will be fixed in a future release.