how to separate xml block

Post questions here relative to DataStage Server Edition for such areas as Server job design, DS Basic, Routines, Job Sequences, etc.

Moderators: chulett, rschirm, roy

Post Reply
Rimi
Participant
Posts: 8
Joined: Wed Feb 28, 2007 10:25 am

how to separate xml block

Post by Rimi »

Hi All,

My job is XmlInput - trasformer - xmloutput

Expected output:
- <Collection Name="Columns" Type="OutputColumn">
- <SubRecord>
<Property Name="Name">sl</Property>
<Property Name="SqlType">4</Property>
<Property Name="Precision">10</Property>
<Property Name="Scale">0</Property>
</SubRecord>
- <SubRecord>
<Property Name="Name">tcode</Property>
<Property Name="SqlType">12</Property>
<Property Name="Precision">255</Property>
<Property Name="Scale">0</Property>
</SubRecord>
</Collection>


Output i am getting :
- <Collection Name="Columns" Type="OutputColumn">
- <SubRecord>
<Property Name="Name">sl</Property>
<Property Name="SqlType">4</Property>
<Property Name="Precision">10</Property>
<Property Name="Scale">0</Property>
<Property Name="Name">tcode</Property>
<Property Name="SqlType">12</Property>
<Property Name="Precision">255</Property>
<Property Name="Scale">0</Property>
</SubRecord>
</Collection>

In my metadata I have columns like

CollectionName
CollectionType
PropertyName
SubRecordPropertyValue

How can I separate both SubRecord block?
I think if I have any attribute value in SubRecord block then it is Possible to separate.How to add attribute in SubRecord.

I will really appreciate any advice you can provide to make this work.

Thanks
shilpa79
Participant
Posts: 131
Joined: Thu Jan 20, 2005 5:59 pm
Location: Virginia

Re: how to separate xml block

Post by shilpa79 »

Did u import .xsd file or .xml file . If u have schema of that particular file then u can modify and add one more arrtibute.
Let me know If I misunderstood anything.
Post Reply