cancel
Showing results for 
Search instead for 
Did you mean: 

multiple xsd for service interface

former_member200339
Participant
0 Kudos

Dear All,

I have to develop a proxy to file scenario. The source message consists of number of process orders within a single message. The target message will also be a single message with the same number of PO create segments as the number of process orders.

i.e. 5 process order in source message = 5 PO create segments in target message

I am provided two xsd schemas to develop the target segment. There is a field called WERK within each process order and based on the value of the field the PO create segment can be of either type-1 or type-2.

i.e. if WERK equal to 001 then PO create based on xsd-1 and if WERK not equal to 001 then PO create is based on xsd-2

Please provide me some idea on the following:

1. How can I develop a service interface based on two xsd.

2. Is there any way I can combine the two xsd into one.

3. How can I get the xml structure from the xsd.

Thanks and Regards,

Rana Brata De

Accepted Solutions (1)

Accepted Solutions (1)

anupam_ghosh2
Active Contributor
0 Kudos

Hi Rana Brata,

                          Did you check this blog

http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/90dcc6f4-0829-2d10-b0b2-c892473f1...

Regards

Anupam

Answers (4)

Answers (4)

nabendu_sen
Active Contributor
0 Kudos

Hi Rana,

I think the Receiver is same for both the conditions. You can write XPath condition in Interface determination to choose the Operation Mapping at run time. You can define 2 different Service Interface and 2 different OM. Find the below screenshot of the OM XPath.

Regards,

Nabendu.

Former Member
0 Kudos

i am from bacau

iaki_vila
Active Contributor
0 Kudos

HI Rana,

1. How can I develop a service interface based on two xsd.

You can follow any previous answers. Also, you can use n XSL mapping (or java), on this way you can import a dummy schema in the receiver side and generate the output with its logic in the xsl mapping (java mapping).

2. Is there any way I can combine the two xsd into one.

You can use the xsd clausules<xsd:import /> or <xsd:include /> in one of the two files refefering the other..

3. How can I get the xml structure from the xsd.

As Abishek said from the message mapping, opertation mapping, etc. Also with external tools like XMLSpy or free xml editor.

Regards.

former_member208404
Participant
0 Kudos

Hi Rana Brata,

1.) One way of doing is to create two service interfaces with those two xsd.

2.) Do a multiple mapping with the two xsd on the target side. In the message mapping you can put that logic and populate the required message.

3.) Once the mapping is done, you can download the xml from there.

Regards

Abhishek

ambrish_mishra
Active Contributor
0 Kudos

HI Rana Brata De,

You need to do multi mapping to achieve this. Import both XSDs as external definition and choose both the definitions as target. Create each based on werks.

Ambrish