【问题标题】:xpath/xquery sql - Get all valuesxpath/xquery sql - 获取所有值
【发布时间】:2011-09-27 10:44:51
【问题描述】:

嗨,我有一个 xml..

<string>1</string>
<string>2</string>
<string>3</string>
<string>4</string>
<string>11</string>
<string>1211</string>
<string>12331</string>

如何在 SQL 中使用 xpath/xquery 获取所有值

谢谢

【问题讨论】:

    标签: sql xpath xquery


    【解决方案1】:

    xpath //string 将返回内部 xml 中的所有值,xpath /string 将仅返回根节点中的值。

    要在 sql 中使用它,请查看此帖子 XPath to fetch SQL XML value

    【讨论】:

      【解决方案2】:

      在oracle数据库中

      你有XMLType (see this) 数据类型..

      通过这个数据类型你可以得到所有的值..

      所有的例子都在那里,请浏览那个网站。

      【讨论】:

        猜你喜欢
        • 1970-01-01
        • 1970-01-01
        • 1970-01-01
        • 1970-01-01
        • 1970-01-01
        • 1970-01-01
        • 2011-01-24
        • 2023-03-27
        • 1970-01-01
        相关资源
        最近更新 更多