开发者

xpath/xquery sql - Get all values

开发者 https://www.devze.com 2023-04-07 16:55 出处:网络
Hi I have a blob of xml.. <string>1</string> <string>2</string> <string>3</string>

Hi I have a blob of xml..

<string>1</string>
<string>2</string>
<string>3</string>
<string>4</string>
<string&g开发者_如何学JAVAt;11</string>
<string>1211</string>
<string>12331</string>

how would I get all the values using xpath/xquery in SQL

Thanks


The xpath //string will return all the values in the intire xml the xpath /string will return only the values in the root node.

And for using it in sql look at this post XPath to fetch SQL XML value


in oracle database

you have XMLType (see this) data type..

by this datatype you can get all the value..

all the examples are there itself, please go through that site.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号