0
INPUT:SQL服務器 - 對於XML路徑(嵌入元素)
SELECT EmpName AS [Name],
EmpDOB AS [Birthdate],
EmpSalary AS [WageAmount],
Add1 AS [Address1],
Add2 AS [Address2],
Mobile AS [Mobile]
FROM Employee
FOR XML PATH
OUTPUT:(工作正常)
<Employee>
<Name>Conrad</Name>
<Birthdate>14-oct-76</BirthDate>
<WageAmount>10000</WageAmount>
<AdditionalInfo>
<Address1>Washington DC</Address1>
<Address2>DC</Address2>
<Mobile>989898989</Mobile>
</AdditionalInfo>
</Employee>
我能夠生成輸出 - 但我想這個元素下面的移動標籤添加(接點式元素 - 我們如何才能增加這個)
<Mobile>989898989</Mobile>
**<ContactType><mobilephone/></ContactType>**