如何使用进度4gl dom读取具有多个元素的xml文件并写入临时表?

问题描述 投票:0回答:1

[请帮助我阅读此xml文件并使用进度4gl写入临时表

我的xml文件如下所示。

 <?xml version="1.0" encoding="UTF-8"?>

        <bookstore>
          <bookone>
            <title>Everyday Italian</title>
            <author>Giada De Laurentiis</author>
            <year>2005</year>
            <price>30.00</price>
          </bookone>

          <cars>
            <model>
            <plate>12345</plate>
            <purchase>04/03/2011</purchase>
            <insurence>yes</insurence>
            </model>

          <model>
          <plate>56789</plate>
          <purchase>04/03/2011</purchase>
          <insurence>no</insurence>
          </model>

        </cars>

        <booktwo>
            <title>XQuery Kick Start</title>
            <author>James McGovern</author>
            <author>Per Bothner</author>
            <author>Kurt Cagle</author>
            <author>James Linn</author>
            <author>Vaidyanathan Nagarajan</author>
            <year>2003</year>
            <date>02/05/2009</date>
          </booktwo>


        </bookstore>

我已经尝试过使用重复语句的代码,但是不起作用。

xml dom temp-tables openedge progress-4gl
1个回答
0
投票
Progress 4gl带有XML的内置解析器。有萨克斯和唐。实际上,Sax解析器对您将更有用,并且在文档中有一个关于如何使用它的很好的起点,这里:https://documentation.progress.com/output/ua/OpenEdge_latest/index.html#page/dvxml/example-code-3a-reading-customer-data-and-writing.html
© www.soinside.com 2019 - 2024. All rights reserved.