xml schema的使用
在.net中用sql语句从数据库中取得的数据怎样才能通过.xsd文件转换为规定格式的xml文件呢?
如取出的数据直接用getxml()方法得到的结果是:
<item>
<bookid>1</bookid>
<bookname>.net高级编程</bookname>
<authorid>1</authorid>
<authorname>John</authorname>
<authorid>2</authorid>
<authorname>Ted</authorname>
</item>
希望使用.xsd得到下面的结果
<item>
<book id=1 name=.net高级编程></bookid>
<author id=1 name=John></authorid>
<author id=2 name=Ted></authorid>
</item>
谢谢!