Create distinct XML complexes

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
just4geeks
Premium Member
Premium Member
Posts: 644
Joined: Sat Aug 26, 2006 3:59 pm
Location: Mclean, VA

Create distinct XML complexes

Post by just4geeks »

I am reading contents in a table and writing them to an XML file using the XML Output stage.

Table Contents are as follows,

Code: Select all

ColA ColB ColC
A1      B1   C1
A2      B1   C1
A3      B3   C3
The expected XML output is as follows,

Code: Select all

	<tag>
		<tagColA>A1</tagColA>
		<tagColB>B1</tagColB>
		<tagColC>C1</tagColC>
	</tag>
	<tag>
		<tagColA>A2</tagColA>
		<tagColB>B1</tagColB>
		<tagColC>C1</tagColC>
	</tag>
	<tag>
		<tagColA>A3</tagColA>
		<tagColB>B3</tagColB>
		<tagColC>C3</tagColC>
	</tag>
However, the current output is as follows,

Code: Select all

	<tag>
		<tagColA>A1</tagColA>
		<tagColA>A2</tagColA>
		<tagColB>B1</tagColB>
		<tagColC>C1</tagColC>
	</tag>
	<tag>
		<tagColA>A3</tagColA>
		<tagColB>B3</tagColB>
		<tagColC>C3</tagColC>
	</tag>
Any ideas on how do I get the expected output?
Attitude is everything....
pnpmarques
Participant
Posts: 35
Joined: Wed Jun 15, 2005 9:27 am

Post by pnpmarques »

Hello,
Please check viewtopic.php?t=148651&highlight=

Regards,
Pedro.
Post Reply