MVSFORUMS.com Forum Index MVSFORUMS.com
A Community of and for MVS Professionals
 
 FAQFAQ   SearchSearch   Quick Manuals   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

XML PARSE issues in COBOL - Runtime error

 
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> Application Programming
View previous topic :: View next topic  
Author Message
lakshmiraya
Beginner


Joined: 15 Jun 2007
Posts: 7
Topics: 3
Location: Pune

PostPosted: Tue Oct 09, 2007 12:05 am    Post subject: XML PARSE issues in COBOL - Runtime error Reply with quote

Hi,
I coded a program that uses XML PARSE to convert xml format to flat file.

This program works fine if the whole xml file is in one record. Now that the data in input file is more and it can't fit in one record. It will be in multi-records. To accomodate this I need to change the program.

For example:
there is a header record and 10 detail records. The program is working fine if all the records are given in one record (xml format).
New format will have header as 1st rec, 1st det rec as 2nd rec, 2nd det rec as 2nd rec, and so on 10th det rec as 10th rec.

While running the program some errors occured.

115 - The parser reached the end of the document while scanning character data in element content.

317 - The parser cannot determine the document encoding. The document might be damaged.

The data is proper in input file. I tried giving only one record with proper data.

Any idea how to resolve these errors?

Please help.

Thanks...
Back to top
View user's profile Send private message AIM Address Yahoo Messenger MSN Messenger
CICS Guy
Intermediate


Joined: 30 Apr 2007
Posts: 292
Topics: 3

PostPosted: Tue Oct 09, 2007 4:11 am    Post subject: Reply with quote

The 115 is because the parse ended while some tags did not close....

The 317 is because the parse needs to start with that initial tag, "<?xml"{, I think.....

XML is not a process that lends itself to being broken down, it is an all or nothing sort of thing....About the only thing you can do is to reblock the entire message into a single area before parsing it.
What environment are you running in that you can not keep the message whole?
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> Application Programming All times are GMT - 5 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


MVSFORUMS
Powered by phpBB © 2001, 2005 phpBB Group