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



Joined: 04 Jun 2013
Posts: 62

Points: 739

Post Posted: Wed Aug 15, 2018 5:02 am Reply with quote    Back to top    

DataStage® Release: 11x
Job Type: Parallel
OS: Unix
Hi,
I have a problem for which I was unable to find some solution from the search. Posting it here.

I have an exiting job with xml unpack stage to read the xml file and output data to some text files.

Now there is a change in xsd from the source, change of namespace and additional elements

Earlier the namespace is ......../Event/1.0 and now it is changed to ......../Event/2.0 and so when I replace the xsd definition and in the XML_parser setup, from DocumentRoot when I browse for the new xsd all the earlier mappings(output links mapping) are throwing errors and this is requiring me to remap every column.

To validate from my end, in the new xsd I have retained the earlier namespace ......../Event/1.0 and repeated above steps passing through XMLParse Setup and Document root i do not see any errors.

So I concluded it is only because of change of namespace, the errors are thrown.

I have around 600 columns to be mapped for the existing job.
Can anyone know a better way to handle this(new namespace) so that I can avoid remapping of all columns

_________________
Thanks,
HK
*Go GREEN..Save Earth*
eostic

Premium Poster



Group memberships:
Premium Members

Joined: 17 Oct 2005
Posts: 3782

Points: 30373

Post Posted: Thu Aug 16, 2018 4:37 am Reply with quote    Back to top    

Depending on the size of the document, one thought is to just pre-process it....put the entire xml document into a single longvarchar, and then pass it thru a Transformer and hit it with something lik ...

_________________
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: 42762
Location: Denver, CO
Points: 220350

Post Posted: Thu Aug 16, 2018 6:27 am Reply with quote    Back to top    

That "preprocess" suggestion is something we had to do in a somewhat similar situation. A Gov't vendor provided XML with a missing namespace which caused our parsing job to fail, something they were not able / willing to correct. So now we pre-process them and add in what is missing using nawk and then load the resulting files.

_________________
-craig

Research shows that 6 out of 7 dwarves aren't happy
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