ProductName AS [Product!2!ProductName!element]
FROM Categories
JOIN Products ON Categories.CategoryID = Products.CategoryID AND ProductID <5
WHERE Categories.CategoryID < 3
ORDER BY [Category!1!ID] DESC,[Product!2!ProductID!element] ASC
FOR XML EXPLICIT
返回结果:
3
Aniseed Syrup
4
Chef Anton's Cajun Seasoning
1
文章来源于领测软件测试网 https://www.ltesting.net/