DetailPage-MSS-KB

Microsoft small business knowledge base

Article ID: 978629 - Last Review: October 11, 2011 - Revision: 2.0

Microsoft distributes Microsoft SQL Server 2008 fixes as one downloadable file. Because the fixes are cumulative, each new release contains all the hotfixes and all the security fixes that were included with the previous SQL Server 2008 fix release.

On This Page

SYMPTOMS

Consider the following scenario. In a Microsoft SQL Server 2008 database, a deadlock occurs. Then, you use the system_health Extended Event session to capture the deadlock graph. In this scenario, you receive the following error message:
Msg 9436, Level 16, State 1, Line 1
XML parsing: line 54, character 12, end tag does not match start tag
For example, you run the following query to export the buffer_ring target from the system_health session when a deadlock occurs:
select XEventData.XEvent.value('(data/value)[1]', 'varchar(max)') as DeadlockGraph
FROM
(select CAST(target_data as xml) as TargetData
from sys.dm_xe_session_targets st
join sys.dm_xe_sessions s on s.address = st.event_session_address
where name = 'system_health') AS Data
CROSS APPLY TargetData.nodes ('//RingBufferTarget/event') AS XEventData (XEvent)
where XEventData.XEvent.value('@name', 'varchar(4000)') = 'xml_deadlock_report'
In this example, the query returns the correct result.

However, you can also run the following query to cast this deadlock graph in XML format:
select cast(XEventData.XEvent.value('(data/value)[1]', 'varchar(max)') as xml) as DeadlockGraph
FROM
(select CAST(target_data as xml) as TargetData
from sys.dm_xe_session_targets st
join sys.dm_xe_sessions s on s.address = st.event_session_address
where name = 'system_health') AS Data
CROSS APPLY TargetData.nodes ('//RingBufferTarget/event') AS XEventData (XEvent)
where XEventData.XEvent.value('@name', 'varchar(4000)') = 'xml_deadlock_report'
In this situation, you expect to see the deadlock graph in XML format. Even if the deadlock graph is displayed incorrectly, you still expect to see valid XML content from the xml_deadlock_report report. However, you receive the following error message:
Msg 9436, Level 16, State 1, Line 1
XML parsing: line 54, character 12, end tag does not match start tag

CAUSE

This problem occurs because the code path that generates the XML schema for the deadlock graph skips over the closing tag of the victim-list element. Additionally, the code path adds an unnecessary tag for the deadlock element.

RESOLUTION

The fix for this issue was first released in Cumulative Update 6 for SQL Server 2008 Service Pack 1. For more information about this cumulative update package, click the following article number to view the article in the Microsoft Knowledge Base:
977443  (http://support.microsoft.com/kb/977443/LN/ ) Cumulative update package 6 for SQL Server 2008 Service Pack 1
Note Because the builds are cumulative, each new fix release contains all the hotfixes and all the security fixes that were included with the previous SQL Server 2008 fix release. We recommend that you consider applying the most recent fix release that contains this hotfix. For more information, click the following article number to view the article in the Microsoft Knowledge Base:
970365  (http://support.microsoft.com/kb/970365/LN/ ) The SQL Server 2008 builds that were released after SQL Server 2008 Service Pack 1 was released
Microsoft SQL Server 2008 hotfixes are created for specific SQL Server service packs. You must apply a SQL Server 2008 Service Pack 1 hotfix to an installation of SQL Server 2008 Service Pack 1. By default, any hotfix that is provided in a SQL Server service pack is included in the next SQL Server service pack.

SQL Server 2008 R2

Important You must install this fix if you are running SQL Server 2008 R2.

The fix for this issue was first released in Cumulative Update 1. For more information about how to obtain this cumulative update package for SQL Server 2008 R2, click the following article number to view the article in the Microsoft Knowledge Base:

981355 (http://support.microsoft.com/kb/981355) Cumulative Update package 1 for SQL Server 2008 R2
Note Because the builds are cumulative, each new fix release contains all the hotfixes and all the security fixes that were included with the previous SQL Server 2008 R2 fix release. We recommend that you consider applying the most recent fix release that contains this hotfix. For more information, click the following article number to view the article in the Microsoft Knowledge Base:

981356 (https://vkbexternal.partners.extranet.microsoft.com/VKBWebService/ViewContent.aspx?PortalId=1&scid=kb;en-US;981356) The SQL Server 2008 R2 builds that were released after SQL Server 2008 R2 was released

STATUS

Microsoft has confirmed that this is a problem in the Microsoft products that are listed in the "Applies to" section.

REFERENCES

For information about the Incremental Servicing Model for SQL Server, click the following article number to view the article in the Microsoft Knowledge Base:
935897  (http://support.microsoft.com/kb/935897/ ) An Incremental Servicing Model is available from the SQL Server team to deliver hotfixes for reported problems

For more information about the naming schema for SQL Server updates, click the following article number to view the article in the Microsoft Knowledge Base:
822499  (http://support.microsoft.com/kb/822499/ ) New naming schema for Microsoft SQL Server software update packages

For more information about software update terminology, click the following article number to view the article in the Microsoft Knowledge Base:
824684  (http://support.microsoft.com/kb/824684/ ) Description of the standard terminology that is used to describe Microsoft software updates

APPLIES TO
  • Microsoft SQL Server 2008 R2 Standard
  • Microsoft SQL Server 2008 R2 Enterprise
  • Microsoft SQL Server 2008 R2 Developer
  • Microsoft SQL Server 2008 R2 Workgroup
  • Microsoft SQL Server 2008 Standard
  • Microsoft SQL Server 2008 Enterprise
  • Microsoft SQL Server 2008 Developer
  • Microsoft SQL Server 2008 Workgroup
Keywords: 
kbexpertiseadvanced kbsurveynew kbqfe kbfix KB978629
Share
Additional support options
Ask The Microsoft Small Business Support Community
Contact Microsoft Small Business Support
Find Microsoft Small Business Support Certified Partner
Find a Microsoft Store For In-Person Small Business Support