Page 1 of 1

XML stage

Posted: Mon Mar 09, 2009 2:19 pm
by sheema
Hi ,

My job design is as follows

External Source Stage-----> Transformer-------->XML Input stage -------->sequential file.


The problem is we are not able to read the data properly with a single key.
When I download the metadata for the xml file,we have 5 columns which are specified as keys.
Can some one help me in this regard.

Thanks

Posted: Mon Mar 09, 2009 2:29 pm
by eostic
Quick glance, it looks like there are at least 3 independently repeating paths..... comment, custom field list, and lineitem. Size is a sub repeating group of line item.

You do each in its own link...and one repeating element as "key" for each link.

Ernie

Posted: Mon Mar 09, 2009 2:57 pm
by sheema
So I should have three more xml stages after i read from the first xml stage.Am I right?Can you explain me the below in little detail.

You do each in its own link...and one repeating element as "key" for each link.

I am totally new to the XML stage,so kindly help me out.

Thanks in Advance.

Posted: Mon Mar 09, 2009 3:48 pm
by eostic
Do some searches...there are a lot of threads here on XML....there is a document referenced in many of the threads on Best Practices...it is at Kim Duke's web site....an absolute must read .....the doc on XML stages is good also.....I have a few bits on xml in my blog.

Each Link is a relational path thru your xml structure. So...for instance, you might have a single link for the lineitem and size elements, selecting one element from the size node for your repeating element. You need to import the structure via the XML metadata Importer (again, see the doc for more details). Your structure is fairly straightforward, so you shouldn't have too much problem. Start with something simple like just the header info, and then move into the repeating nodes.

Ernie

Re: XML stage

Posted: Tue Mar 17, 2009 1:54 am
by manu.dwhds
Hi , you need to use rowgenarator----------->Transformer--------->xmlinputstage--------->write datasets(how many you want outputs)

If your xml chunks are repeting take it as a key coloum and write into separe datasets (For Every key you need to take separate dataset) Then only you are able to read that reapeted chunks .