× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



I agree...I think the XML is missing <Order> and </Order> tags as well.
I just wanted to be sure there was no way to define the DS to handle this
type of structure before I go back to the supplier of the XML and tell them
they need to add tags to group each order.

And if they respond with "Tough luck kid", what is the alternative?
I assume %Handler could deal with this? Or if this is indeed a flaw in the
XML, is it a fatal flaw that MUST be corrected when the XML itself is
created?

- Steve


On Thu, Mar 14, 2019 at 12:46 PM Peter Dow <petercdow@xxxxxxxxx> wrote:

Hi Stephen,

I'm no expert, but it looks like your XML is missing a tag for each
order to group that orders information. Something like:

<OrderInformation>
<Order>
<OrderID>9000</OrderID>
<Brand>MyBrand</Brand>
<Division>Div100</Division>
<InvoiceOrderItems>
<Item Num="1">
<ItemShipDate>2019-01-16T00:00:07+00:00</ItemShipDate>
<Carrier>FEDEX</Carrier>
</Item>
<Item Num="2">
<ItemShipDate>2019-01-16T00:00:07+00:00</ItemShipDate>
<Carrier>FEDEX</Carrier>
</Item>
</InvoiceOrderItems>
</Order>
<Order>
<OrderID>9001</OrderID>
<Brand>MyBrand</Brand>
<Division>Div100</Division>
<InvoiceOrderItems>
<Item Num="1">
<ItemShipDate>2019-01-16T00:00:07+00:00</ItemShipDate>
<Carrier>FEDEX</Carrier>
</Item>
</InvoiceOrderItems>
</Order>
</OrderInformation>

Then your data structure would be

Dcl-DS OrderInformation;
countOrder int(5);
Dcl-DS Order;
OrderID varchar(50) ;
Brand varchar(50) ;
Division varchar(50) ;
Dcl-DS InvoiceOrderItems;
countItem int(5);
Dcl-DS Item Dim(10);
ItemShipDate varchar(50) ;
Carrier varchar(50) ;
End-DS ;
End-DS ;
End-DS ;
End-DS ;

--
*Peter Dow* /
Dow Software Services, Inc.
909 793-9050
petercdow@xxxxxxxxx <mailto:petercdow@xxxxxxxxx>
pdow@xxxxxxxxxxxxxx <mailto:pdow@xxxxxxxxxxxxxx>


As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:
Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.