DSXchange: DataStage and IBM Websphere Data Integration Forum
View next topic
View previous topic
Add To Favorites
Author Message
cosec



Group memberships:
Premium Members

Joined: 08 May 2007
Posts: 230

Points: 1913

Post Posted: Tue Jul 26, 2016 9:58 pm Reply with quote    Back to top    

DataStage® Release: 8x
Job Type: Server
OS: Unix
Hi All,

I am trying to read the contents of an XML file in to a Text File but encounter error when there is a line break in the XML file.

Job Design
XML Source File -> XML Input Stage -> Transformer -> Text File

The job works fine when there is no line break within the XML fields.

However, when there is a line break in one of the fields I encounter error as follows(I have indicated that the column can have terminators):
XML input document parsing failed. Reason: Xalan fatal error (publicId: , systemId: , line: 1, column: 226): Invalid character (Unicode: 0x0)

XML Source File structure example:

<?xml version="1.0" encoding="UTF-8" standalone="yes"?><TBL_A><FIELD1>513</FIELD1><FIELD2>AAAA
01/BBBB</FIELD2></TBL_A>

Any suggestions on how I could avoid the error but without removing the line breaks ?

I would greatly appreciate your advice.
chulett

Premium Poster


since January 2006

Group memberships:
Premium Members, Inner Circle, Server to Parallel Transition Group

Joined: 12 Nov 2002
Posts: 42268
Location: Denver, CO
Points: 217033

Post Posted: Wed Jul 27, 2016 6:43 am Reply with quote    Back to top    

Can you confirm for us what the first stage in your job is - sequential file stage? If so, suggest you replace it with a Folder stage (ideally just passing in the filename and letting the XML ...

_________________
-craig

Watch out where the huskies go and don't you eat that yellow snow
Rate this response:  
Not yet rated
eostic

Premium Poster



Group memberships:
Premium Members

Joined: 17 Oct 2005
Posts: 3723

Points: 29735

Post Posted: Wed Jul 27, 2016 7:08 am Reply with quote    Back to top    

You can process the entire content, or just the name of the file.....the Folder Stage has a "built-in" Table Definition..... notice how it contains the filename and the "record"...this is the actual c ...

_________________
Ernie Ostic

blogit!
Open IGC is Here!
Rate this response:  
Not yet rated
chulett

Premium Poster


since January 2006

Group memberships:
Premium Members, Inner Circle, Server to Parallel Transition Group

Joined: 12 Nov 2002
Posts: 42268
Location: Denver, CO
Points: 217033

Post Posted: Wed Jul 27, 2016 10:20 am Reply with quote    Back to top    

True dat. No clue what the limit is any more but back in the day when we were processing "large" XML files, it seemed better to just pass the URL to the XML Input stage and let it do all of the work. ...

_________________
-craig

Watch out where the huskies go and don't you eat that yellow snow
Rate this response:  
Not yet rated
eostic

Premium Poster



Group memberships:
Premium Members

Joined: 17 Oct 2005
Posts: 3723

Points: 29735

Post Posted: Wed Jul 27, 2016 10:57 am Reply with quote    Back to top    

Yes...true...and largely a factor of the downstream Stage. If you are using a Server Job, the Folder Stage can probably "lift" a bigger XML document than the xmlInput Stage can handle. The xmlInpu ...

_________________
Ernie Ostic

blogit!
Open IGC is Here!
Rate this response:  
Not yet rated
chulett

Premium Poster


since January 2006

Group memberships:
Premium Members, Inner Circle, Server to Parallel Transition Group

Joined: 12 Nov 2002
Posts: 42268
Location: Denver, CO
Points: 217033

Post Posted: Wed Jul 27, 2016 12:05 pm Reply with quote    Back to top    

That same number is in the back of my mind... 200 to 250MB was our limit on our HPUX system, I do believe. Thankfully, our sources generally were of the mind to flood us with a metric crap-ton of smal ...

_________________
-craig

Watch out where the huskies go and don't you eat that yellow snow
Rate this response:  
Not yet rated
Display posts from previous:       

Add To Favorites
View next topic
View previous topic
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



Powered by phpBB © 2001, 2002 phpBB Group
Theme & Graphics by Daz :: Portal by Smartor
All times are GMT - 6 Hours