1
declare @xmlVal xml
set @xmlVal =
'<user>
<token><id>ABC123</id><endDate>2013-06-16 18:48:50.111</endDate></token>
<token><id>XYX456</id><endDate>2014-01-01 18:48:50.111</endDate></token>
</user>'
我需要整個令牌節點作爲XML其中id = ABC123所以出放爲:獲取在SQL Server基於一個內部節點的值父XML節點
<token>
<id>ABC123</id>
<endDate>2013-06-16 18:48:50.111</endDate>
</token>