我实际没有用过2000,但看资料,它对XML的支持非常好,微软的。NET FRAMEWORK 将采用XML做标准的数据交换介质,XML会大有发展

解决方案 »

  1.   

    本人用过sql 2000的xml功能,其潜力不小!!
      

  2.   

    To: Netis_Sun(NS)
    能否谈谈你的使用经验。
      

  3.   

    1、通过sql语句将结果输出在ie中,其结构为xml,当然sql server 2000也提供输出到其他
       的api函数,这里不介绍了;
    2、将数据存储。通过自己或他人的第三方软件进行分析dom化;
    3、对dom进行要求的操作后传输或保存为xml;
      

  4.   

    <%@ Language=VBScript %>
    <!-- 
    file name:genXmlWithSql.asp
    一段在SQl Sever 2000中通过SQL直接输出XML文件的代码
    -->
    <%
    Dim objConn, objCmd, i
    dim strCom
    Set objConn = Server.createobject("ADODB.CONNECTION")
    objConn.Open "Provider=SQLOLEDB.1;Password=;Persist Security Info=True;User ID=sa;Initial Catalog=Northwind;Data Source=hongs"
    Set objCmd = Server.CreateObject("ADODB.Command")
    objCmd.ActiveConnection = objConn
    objCmd.Properties("Output Stream") = Response
    objCmd.Properties("XML Root") = "root"
    objCmd.Properties("Output Encoding")="gb2312"
    'objCmd.Properties("XSL")="genXmlWithSql.xsl"
    strCom="select * from customers"
    if Request.QueryString("strWhere")<>"" then
    strCom=strCom + " where " + Request.QueryString("strWhere")
    end if
    strCom=strCom + " for xml auto,elements"
    objCmd.CommandText=strComResponse.ContentType = "text/xml"
    objCmd.Execute i, , 1024 'adExecuteStream
    Set objCmd = Nothing
    objConn.Close
    Set objConn = Nothing
    %>