I am trying to the get the value of the x:String node (L1.0.0.0) in XML below shown code sample. The XML in the sample is generated by the TFS 2010 when we queue the builds. The XML has two major nodes and Dictionary and x:String and I have tried the query similar to the other stack overflow thread and I have included that under additional research. Any one got any suggestions why my XQuery is not working?
DECLARE @XML XML;
SET @XML = '<Dictionary x:TypeArguments="x:String, x:Object"
xmlns="clr-namespace:System.Collections.Generic;assembly=mscorlib"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
<x:String x:Key="GetVersion">L1.0.0.0</x:String>
</Dictionary>'
;WITH XMLNAMESPACES(
'clr-namespace:System.Collections.Generic;assembly=mscorlib' AS a,
'http://schemas.microsoft.com/winfx/2006/xaml' AS x)
SELECT @XML.value('(/Dictionary/x:String)[1]', varchar(100)) AS BuildLabel
Additional Research Stack Overflow T-SQL, XQuery Invalid Column