Oracle SQL*Loader 可以处理 XML 吗?
Oracle 是否提供 XML 格式文件的标准化上传?我认为用于 XML 输出的规范格式结构 = ROWSET/ROW/columname
可以通过运行具有适当控制文件内容的 sqlldr 再次上传回表中.
但是我在网络上的任何地方都找不到任何关于此的信息,并且试验后的错误消息似乎表明只能将 XML 上传到 XML 类型格式的表格中,我只想在普通表格中上传数据但提供数据XML 格式.
Does Oracle offer a standardized upload of XML formatted files?
I thought that the canonical format that is used for XML output, structure = ROWSET/ROW/columname
, could be uploaded back into the table again, by just running sqlldr with appropriate control file contents.
But I cannot find anything about this anywhere on the web, and error messages after trials seem to indicate that it is only possible to upload XML into XML-type formatted tables, where I just want to upload data in a plain table but supply the data in XML format.
推荐答案
不,SQL*Loader 只能处理平面"文件.
No, SQL*Loader can only process "flat" files.
一种选择是编写一个 XSLT 转换,将 ROWSET/ROW/column
格式转换为文本文件,然后将其导入目标表.
One option is to write an XSLT transformation that turns the ROWSET/ROW/column
format into a text file and then import that into the target table.
另一种选择是将 XML 导入单行,然后使用 Oracle 的 XML 函数从该临时表中选择一个关系结果并将其插入到实际表中.
Another option is to import the XML into a single row, and then use Oracle's XML functions to select a relational result from that staging table and insert it into the real table.
相关文章