× 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.



Well,

the task was to put CRLF between elements and that includes
ending parent nodes. If you have very long node names and you
are deep in the hierarchy and you want to place the elements
in a DB2 file you may truncate the string ... or if you want
to process the records sequential where one record is either
a start/end of a parent node or a text node you can't do it
or at least you have to do a lot of string coding and logic
to do so.

The RPG routine I posted do return a string for each node,
parent start/end node and text node wich mean that I can do
processing on a end node by simple testing, if I had to read
your file, I had to use my RPG routine anyway because I first
had to extract the endnode from the string ;-)




"Dennis Lovelady" <iseries@xxxxxxxxxxxx>
Sent by: rpg400-l-bounces@xxxxxxxxxxxx
16-02-2010 14:53
Please respond to
RPG programming on the IBM i / System i <rpg400-l@xxxxxxxxxxxx>


To
"'RPG programming on the IBM i / System i'" <rpg400-l@xxxxxxxxxxxx>
cc

Subject
RE: Replace 1 Char with 3Char's






and now you will get

<name>Donald Duck</name></head></customer></xml>

in stead of

<name>Donald Duck</name>
</head>
</customer>
</xml>


... and this is a problem because ... (?)

Dennis Lovelady
http://www.linkedin.com/in/dennislovelady
--
Sign seen at a Bangkok dry-cleaners: "Drop your trousers here for best
results."




As an Amazon Associate we earn from qualifying purchases.

This thread ...

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.