Warning: file_get_contents(/data/phpspider/zhask/data//catemap/5/sql/80.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181

Warning: file_get_contents(/data/phpspider/zhask/data//catemap/4/regex/20.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
正则表达式oracle sql_Sql_Regex_Xml_Oracle_Regexp Substr - Fatal编程技术网

正则表达式oracle sql

正则表达式oracle sql,sql,regex,xml,oracle,regexp-substr,Sql,Regex,Xml,Oracle,Regexp Substr,我有一个由两列组成的人员表,第一列是id,第二列是XML,其中包含人员详细信息。 例如,person XML文件可以是: <Person> <name>First Last</name> <address>5 Champ de Mars</address> <city>Paris</city> <country>France</country> &l

我有一个由两列组成的人员表,第一列是id,第二列是XML,其中包含人员详细信息。 例如,person XML文件可以是:

<Person>
    <name>First Last</name>
    <address>5 Champ de Mars</address>
    <city>Paris</city>
    <country>France</country>
    <phone-number>+3312345</phone-number>
</Person>

最后一个
5火星冠军
巴黎
法国
+3312345
我想知道如何使用
regexp\u substr
提取XML中每个参数的值,我尝试使用函数
EXTRACTVALUE
,这给我带来了太多问题。 我毁了甲骨文。 例如,如果查询我提供的XML:
从id=1的人中选择regexp\u substr(XML\u文件,'pattern name')
将导致:
First-Last.

先谢谢你
Yonatan

您在使用EXTRACTVALUE时遇到了什么样的问题

因为这似乎是你需要的


类似于从my_表中选择EXTRACTVALUE(my_xml_列,/Person/name),其中id=
应按要求返回“First Last”。

您在使用EXTRACTVALUE时遇到了什么问题

因为这似乎是你需要的

类似于从my_表中选择EXTRACTVALUE(my_xml_列,/Person/name),其中id=应按要求返回
“First Last”