on 10-16-2007 11:38 AM
Hello all,
<b>My Source is.............</b>
<?xml version="1.0" encoding="UTF-8"?>
<ns0:PersonsMT xmlns:ns0="http://xyz.com/scratchpad">
<Persons>
<Person>
<Name>Smith</Name>
<Height>22</Height>
<Father>
<Name>Paul</Name>
<Height>23</Height>
<Father>
<Name>Sr Paul</Name>
<Height>23</Height>
<Father/>
</Father>
</Father>
</Person>
<Person>
<Name>Brad</Name>
<Height>22</Height>
<Father>
<Name>Luke</Name>
<Height>23</Height>
<Father/>
</Father>
</Person>
</Persons>
</ns0:PersonsMT>
And Target Should look like this........
<?xml version="1.0" encoding="UTF-8"?>
<ns0:PersonsListOutputMT xmlns:ns0="http://xyz.com/scratchpad">
<Persons>
<Person>
<Name>Smith</Name>
<Height>22</Height>
</Person>
<Person>
<Name>Paul</Name>
<Height>23</Height>
</Person>
<Person>
<Name>Sr Paul</Name>
<Height>23</Height>
</Person>
<Person>
<Name>Brad</Name>
<Height>22</Height>
</Person>
<Person>
<Name>Luke</Name>
<Height>23</Height>
</Person>
</Persons>
</ns0:PersonsListOutputMT>
I have to do this only by GUI mapping how to do this.....
With Regards,
Satya Sunil
Hi Sunil
What I understood from your source structure is that for a person you are maintaining an infinite number of ancisters (father's father) details :
<Person>
<Name>Smith</Name>
<Height>22</Height>
<Father>
<Name>Paul</Name>
<Height>23</Height>
<Father>
<Name>Sr Paul</Name>
<Height>23</Height>
<Father/>
</Father>
</Father>
</Person>
There is <Father> inside <Father>. Is this what you intend to do? If so,Is there a limit to the level <Father>?
Am I understanding the source structure right ? If yes, please give me sample of source XML template from the message mapping tool.
Vijendra
Message was edited by:
Vijendra Bhanot
Message was edited by:
Vijendra Bhanot
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi
as per your given structure your source data type will look like
dt_test_source
persons(1..1)
person(0..unbounded)
Name(1..1)
height(1..1)
father(0..unbounded)
name(1..1)
height(1.1)
n ur target structure look like
dt_test_target
persons(1..1)
person(0..unbounded)
Name(1..1)
height(1..1)
by making such a structure you can do the graphical mapping easily.
Thanks
Rinku
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Sunil,
I think you need to use User defined function where in it accepts two inputs 'Persons', 'Father'. You need to write some java code using the concept of Queues and produce the target structure as required.
Regards,
Suraj Kumar
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Sunil,
As your source and target messages are same so there is no need to do mapping, but still if you are intersted in doing mapping just map in one-to-one.
Regards,
Sarvesh
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Sunil,
I have checked you source structure. I think you have created it for you learning purpose. This is wrong example taken by you. You can not create data type with identical names. If structure is correct then it may be that you have made a mistake while posting your structure on SDN. Just confirm it??
Regards,
Sarvesh
Hello,
Source :
DT_Persons Complex Type
Person Element 1....unbounded
Name Element xsd:string 1
Height Element xsd:string 1
Father Element 1....unbounded
Name Element xsd:string 1
Height Element xsd:string 1
TARGET :
DT_Persons Complex Type
Person Element 1....unbounded
Name Element xsd:string 1
Height Element xsd:string 1
Sunil,
See the below mapping, something is missing (???), just create missing node & respective fields. it will work.
<b>SOURCE</b> -
<b>TARGET</b>
DT_Persons Complex Type -
> DT_Persons Complex Type
Person Element 1....unbounded -
> Person Element 1....unbounded
Name Element xsd:string 1 -
> Name Element xsd:string 1
Height Element xsd:string 1 -
> Height Element xsd:string 1
Father Element 1....unbounded -
> <b>??? (field missing, so can not mapped)</b>
Name Element xsd:string 1 -
> <b>??? (field missing, so can not mapped)</b>
Height Element xsd:string 1 -
> <b>??? (field missing, so can not mapped)</b>
Regards,
Sarvesh
Hi Sunil,
I have a doubt. How did you define the recursive structure in the message type/data type.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
83 | |
24 | |
12 | |
9 | |
7 | |
6 | |
5 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.