Quantcast
Channel: IBM Mainframe Computers Forums
Viewing all articles
Browse latest Browse all 8500

COBOL Programming :: XML Parse for large file

$
0
0
Author: muralikrishnan_new
Subject: XML Parse for large file
Posted: Mon Jun 12, 2017 12:50 pm (GMT 5.5)

Hi All,
We are reading a xml documents from variable length file(LRECL=32004 i.e 32K file length).
We observed an issue when the xml content filled with 32000 bytes per line as mentioned below, and the second line starts with the
continuation of the xml tag.
?xml version='1.0' encoding='UTF-8'?><batch xmlns="www.bank.com"><batch-info id="doc_bank_20170518"><batch:sender-identifier>kbc</batch>
</batch-info><documents><documenturl="hasgh://ajhjk@yeuhd/jsdgfhgsdhfgsdhg_1"><lname>Murali</lname><Dept><Team>Development Delivery</Team><Project-
Role>Developer</project-Role></Dept></documents></batch>

a) We tried using only XML-PARSE operation and processing it. It was working fine.
b) But we check validation against a data on DB2 table using SQL, when we parse the second record the Start of Element of not captured in XML-EVENT
instead it skipped the <Project-Role> and capturing as END-OF-Document at first record end byte and next record it says as START-OF-DOCUMENT and throws an "EXCEPTION"
XML-CODE = 0000798819

But when we remove the SQL statement and do the processing , it works fine.

Do we have any logging dataset to capture the XML-PARSE for each element?
Whether it has to do with any memory allocation of the program?
Please help me to resolve the issue. Meanwhile i will try to post if i found anything more
_________________
Thanks,
Murali


Viewing all articles
Browse latest Browse all 8500

Trending Articles