Skip to Content

The goal of this guide is to provide a detailed step by step to import XSD´s schema with external references by using SAP PI tool “Import External Definitions…”


In my case I have worked with a customer who uses OASIS UBL 2.1 as standard to Exchange messages (https://www.oasis-open.org/).

First, customer provides me the XSD nested structure in a zipped file.

/wp-content/uploads/2013/07/1_248140.jpg

/wp-content/uploads/2013/07/2_248168.jpg

Procedure:


All the schemas must be imported under the same namespace to keep the reference amongst them.

/wp-content/uploads/2013/07/3_248169.jpg

Select the menu Tools > Import External Definitions… (We use the massive import tool).

/wp-content/uploads/2013/07/4_248170.jpg

This initializes a wizard

/wp-content/uploads/2013/07/5_248177.jpg

Select the Software Component Version and the Namesapace.

/wp-content/uploads/2013/07/6_248178.jpg

Choose all the XSD files to import, in this step is important to select the option Import All References, so it will automatically reference the XSD’s.

/wp-content/uploads/2013/07/7_248179.jpg

Click ‘Continue’, the message ‘Generate proposals…’ appears.

/wp-content/uploads/2013/07/8_248186.jpg

Finally it show the list of files to import, in the column name ‘Source’ you can see those who has reference to other XSD file.

/wp-content/uploads/2013/07/9_248187.jpg

Sometimes it is necessary to modify a file name since PI doesn´t accept some characters.

/wp-content/uploads/2013/07/10_248188.jpg

At last click ‘Finish’.

/wp-content/uploads/2013/07/11_248192.jpg

E.g. UBLContractNotice main schema has reference to:

UBLCommonAggregateComponents

UBLCommonBasicComponents

UBLCommonExtensionsComponents

/wp-content/uploads/2013/07/12_248193.jpg

/wp-content/uploads/2013/07/13_248194.jpg

if some references are still missing, we will see fields in red on the message as shown in below example.

/wp-content/uploads/2013/07/14_248202.jpg

I hope you find useful this guide.


To report this post you need to login first.

7 Comments

You must be Logged on to comment or reply to a post.

  1. Suman Saha

    Hi Rodrigo,

    Thanks for your input.

    We are having a requirement where we need to import an WSDL which refers to an XSD from intranet(accessible from PI server).We have given the full path of that XSD as the schemaLocation in WSDL file. But in PI can’t find the location of that XSD file whereas if we paste the location in browser, the XSD structure is visible.

    Please suggest what else should we do?

    Regards,

    Suman

    (0) 
    1. Rodrigo Ferradas Post author

      Hi Suman,

      Sorry for the delay, what I would do will be download the XSD from intranet and import it in the same namespace than the WSDL, and then check if the flap “External References” has the column “Source” and “Name” complete, this means that the reference with the XSD schema is good, If not please refer to the following link where I explain what to do.

      http://scn.sap.com/thread/3611445

      I have a query, the WSDL has the “SchemaLocation” tag complete or you have to complete manually? because I think you have to do this with an application to créate WSDLs like XML Spy, I remembered one time i did it manually and when I imported the WSDL did not appear the reference so I had to use the App I mentioned to créate the WSDL.

      I hope this help you.

      Best regards,

      Rodrigo.

      (0) 

Leave a Reply