XML output Stage

Post questions here relative to DataStage Enterprise/PX Edition for such areas as Parallel job design, Parallel datasets, BuildOps, Wrappers, etc.

Moderators: chulett, rschirm, roy

Post Reply
suneelchallagali
Participant
Posts: 251
Joined: Tue Dec 02, 2008 3:09 pm

XML output Stage

Post by suneelchallagali »

I am using simple Job

Seq_File > Xml_Input > Seq_File

<xml>
<id>1</id>
<id>2</id>
<id>3</id>
<car>audi</car>
<car>acura</car>
<car>Honda</car>
</xml>

Output i am getting as

Name ID
audi 1
acura 1
Honda 1

please help me out to get associate ID's for Associate name fields such as

Name ID
audi 1
acura 2
Honda 3


thank you
eostic
Premium Member
Premium Member
Posts: 3838
Joined: Mon Oct 17, 2005 9:34 am

Post by eostic »

Sadly, that's a poorly designed xml document. The id's and car names should be together in their own repeating element if they are truly related as you have indicated. This looks like a simple example...do you know anything more about the document? Is the array size always 3? Is it entirely variable? Anything else that you know about it?

Ernie
Last edited by eostic on Wed Feb 03, 2010 12:24 am, edited 1 time in total.
Ernie Ostic

blogit!
<a href="https://dsrealtime.wordpress.com/2015/0 ... ere/">Open IGC is Here!</a>
eostic
Premium Member
Premium Member
Posts: 3838
Joined: Mon Oct 17, 2005 9:34 am

Post by eostic »

Sadly, that's a poorly designed xml document. The id's and car names should be together in their own repeating element if they are truly related as you have indicated. This looks like a simple example...do you know anything more about the document? Is the array size always 3? Is it entirely variable? Anything else that you know about it?

Ernie
Ernie Ostic

blogit!
<a href="https://dsrealtime.wordpress.com/2015/0 ... ere/">Open IGC is Here!</a>
suneelchallagali
Participant
Posts: 251
Joined: Tue Dec 02, 2008 3:09 pm

Post by suneelchallagali »

Thanks for your response eostic. Actaully just for testing the xml input and output stages i have took the example. If possible can you guide me with this stages like how to use it
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

That's what the manuals are for. It may even be that IBM offers a class in using XML with DataStage. Check it out on their website - training is usually buried under Services.

You couldn't afford what IBM would charge for Ernie!
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
eostic
Premium Member
Premium Member
Posts: 3838
Joined: Mon Oct 17, 2005 9:34 am

Post by eostic »

Thank you Ray.........but that being said, do a few minutes of searching...you'll find hundreds of threads on xml in this forum with all kinds of input from myself and many others......including examples, etc. etc. etc. etc. etc. etc.

Ernie
Ernie Ostic

blogit!
<a href="https://dsrealtime.wordpress.com/2015/0 ... ere/">Open IGC is Here!</a>
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

One of the best references out there is here.
-craig

"You can never have too many knives" -- Logan Nine Fingers
suneelchallagali
Participant
Posts: 251
Joined: Tue Dec 02, 2008 3:09 pm

Post by suneelchallagali »

Thank you all for your support and help!!!!
Post Reply