删除xml没有值的节点
我要删除 没有值的节点 <price/>
DECLARE @myDoc xml
SET @myDoc = ' <root>
<item ID="1">
<title>aaa </title>
<author>bbb </author>
<price>10 </price>
</item>
<item ID="2">
<title>hhh </title>
<author>hkkk </author>
<price/>
</item>
</root>'
SELECT @myDoc
我要的结果是
DECLARE @myDoc xml
SET @myDoc = ' <root>
<item ID="1">
<title>aaa </title>
<author>bbb </author>
<price>10 </price>
</item>
<item ID="2">
<title>hhh </title>
<author>hkkk </author>
&
相关问答:
从数据库中查询一张表的数据
select 部门,姓名 from tb
如何才能生成下面的xml格式文件
<folder state="unchecked" label="全部">
<folder state="unchecked" isBra ......
<?xml version="1.0" encoding="UTF-8" ?>
<root>
<video>
<device deviceid="\\?\usb#vid_0c45&pid_613b#5&2d0620de& ......
在action中至少有4个方法,每个方法接受一种请求,例如四个方法最简单的就是增删改查,每一种操作,需要校验的action属性是不同的,校验属性的规则也是不同的,怎么样才能使用xml的输入校验?
如果是使用actionName ......
在Sqlserver数据库Northwinds中创建一个存储过程,
该存储过程有两个参数,nvarchar(5)类型的@customerID 是customers表的customerID, xml类型的参数@xmlCustOrder是输出参数,存储过程将根据orders和customers 表 ......