Skip to Content
avatar image
Former Member

Problem with external definitions (XSD)

Hi people,

I've read a lot about this issue but I just couldn't find a way to solve it.

After loading and XSD schema as an ED, I tried to create a message interface but the ED created isn't available.

Nothing appears in "MESSAGES" and "EXTERNAL REFERENCES" tabs of the ED.

I've already checked the XSD (using XML Spy) and it's OK.

I'm not sure if it's helpful but, here is an example:

-


<?xml version="1.0" encoding="utf-8"?>

http://www.w3.org/2001/XMLSchema" xmlns=" https://www.fazenda.sp.gov.br/wsAlcoolCombustivel/ws/schemas/Autorizacao.xsd" targetNamespace=" https://www.fazenda.sp.gov.br/wsAlcoolCombustivel/ws/schemas/Autorizacao.xsd" elementFormDefault="qualified" version="1.1">

<xs:complexType name="autorizacoesType" id="autorizacoesType">

<xs:sequence minOccurs="0" maxOccurs="unbounded">

<xs:sequence minOccurs="1" maxOccurs="250">

<xs:element name="autorizacao" type="autorizacaoType" />

</xs:sequence>

</xs:sequence>

</xs:complexType>

<xs:complexType name="autorizacaoType" id="autorizacao">

<xs:sequence minOccurs="1" maxOccurs="1">

<xs:element name="dadosAutorizacao" type="dadosAutorizacaoType" />

</xs:sequence>

<xs:attribute name="idRequisicao" type="idRequisicaoType" use="optional">

</xs:attribute>

</xs:complexType>

<xs:complexType name="dadosAutorizacaoType" id="dadosAutorizacaoType">

<xs:sequence minOccurs="1" maxOccurs="1">

<xs:element name="dataRequisicao" type="dataRequisicaoType" minOccurs="1" maxOccurs="1" />

<xs:element name="cnpjRemetente" type="cnpjType" minOccurs="1" maxOccurs="1" />

<xs:element name="cnpjDestinatario" type="cnpjType" minOccurs="1" maxOccurs="1" />

<xs:element name="ufDestinatario" type="ufType" minOccurs="1" maxOccurs="1" />

<xs:element name="codAutorizacao" type="codAutorizacaoType" minOccurs="1" maxOccurs="1" />

<xs:element name="mensagemRetorno" type="xs:string" minOccurs="1" maxOccurs="1" />

</xs:sequence>

</xs:complexType>

<xs:simpleType name="idRequisicaoType" id="idRequisicaoType">

<xs:restriction base="xs:positiveInteger">

<xs:pattern value="\d{1,6}" />

</xs:restriction>

</xs:simpleType>

<xs:simpleType name="dataRequisicaoType" id="dataRequisicaoType">

<xs:restriction base="xs:string">

<xs:pattern value="\d/\d/\d \d:\d:\d" />

</xs:restriction>

</xs:simpleType>

<xs:simpleType name="cnpjType" id="cnpjType">

<xs:restriction base="xs:positiveInteger">

<xs:pattern value="\d" />

</xs:restriction>

</xs:simpleType>

<xs:simpleType name="ufType" id="ufType">

<xs:restriction base="xs:string">

<xs:enumeration value="SP" />

<xs:enumeration value="TO" />

</xs:restriction>

</xs:simpleType>

<xs:simpleType name="codAutorizacaoType" id="codAutorizacaoType">

<xs:restriction base="xs:string">

<xs:pattern value="\d{0,20}" />

</xs:restriction>

</xs:simpleType>

<xs:element name="root">

<xs:complexType>

<xs:sequence>

<xs:element name="nrAutorizacoes" type="xs:integer" minOccurs="1" maxOccurs="1" />

<xs:element name="autorizacoes" minOccurs="1" maxOccurs="1" type="autorizacoesType" />

</xs:sequence>

</xs:complexType>

</xs:element>

</xs:schema>

-


Can anyone give me a hand?

Thanks,

Rodrigo.

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

4 Answers

  • avatar image
    Former Member
    Dec 29, 2006 at 06:22 PM

    Rodrigo,

    After logging into your Integration Repository --> Right Click on External Definition --> Give the name of External Definition --> Then click on Create.

    Here there is a drop down box. Click on XSD and import your external definition. Then after this save.

    I think you are missing something in this process. Try out once again.

    ---Satish

    Add comment
    10|10000 characters needed characters exceeded

    • Former Member Former Member

      Hi...

      actually that's what I did. I imported the XSD from my computer and, manually specified the SOURCE.

      I can see the "IMPORTED DOCUMENT" and the "WSDL" but the tabs "MESSAGES" and "EXTERNAL REFERENCES" are empty.

      The ED is active but it's not available when I try to create the MESSAGE INTERFACE.

      Thanks again!!!!

      Rodrigo.

  • avatar image
    Former Member
    Dec 29, 2006 at 06:45 PM

    Hi,

    Such kind of error ucccurs due bto problem in XSD.

    check ur XSD.

    Add comment
    10|10000 characters needed characters exceeded

    • Former Member

      Hi ,

      Ur problem is solved ...give me the proper points

      use the following XSD/Manipulated XSD....

      =====================================

      <?xml version="1.0" encoding="utf-8"?>

      http://www.w3.org/2001/XMLSchema">

      <xs:complexType name="autorizacoesType" id="autorizacoesType">

      <xs:sequence minOccurs="0" maxOccurs="unbounded">

      <xs:sequence minOccurs="1" maxOccurs="250">

      <xs:element name="autorizacao" type="autorizacaoType" />

      </xs:sequence>

      </xs:sequence>

      </xs:complexType>

      <xs:complexType name="autorizacaoType" id="autorizacao">

      <xs:sequence minOccurs="1" maxOccurs="1">

      <xs:element name="dadosAutorizacao" type="dadosAutorizacaoType" />

      </xs:sequence>

      <xs:attribute name="idRequisicao" type="idRequisicaoType" use="optional">

      </xs:attribute>

      </xs:complexType>

      <xs:complexType name="dadosAutorizacaoType" id="dadosAutorizacaoType">

      <xs:sequence minOccurs="1" maxOccurs="1">

      <xs:element name="dataRequisicao" type="dataRequisicaoType" minOccurs="1" maxOccurs="1" />

      <xs:element name="cnpjRemetente" type="cnpjType" minOccurs="1" maxOccurs="1" />

      <xs:element name="cnpjDestinatario" type="cnpjType" minOccurs="1" maxOccurs="1" />

      <xs:element name="ufDestinatario" type="ufType" minOccurs="1" maxOccurs="1" />

      <xs:element name="codAutorizacao" type="codAutorizacaoType" minOccurs="1" maxOccurs="1" />

      <xs:element name="mensagemRetorno" type="xs:string" minOccurs="1" maxOccurs="1" />

      </xs:sequence>

      </xs:complexType>

      <xs:simpleType name="idRequisicaoType" id="idRequisicaoType">

      <xs:restriction base="xs:positiveInteger">

      <xs:pattern value="\d{1,6}" />

      </xs:restriction>

      </xs:simpleType>

      <xs:simpleType name="dataRequisicaoType" id="dataRequisicaoType">

      <xs:restriction base="xs:string">

      <xs:pattern value="\d/\d/\d \d:\d:\d" />

      </xs:restriction>

      </xs:simpleType>

      <xs:simpleType name="cnpjType" id="cnpjType">

      <xs:restriction base="xs:positiveInteger">

      <xs:pattern value="\d" />

      </xs:restriction>

      </xs:simpleType>

      <xs:simpleType name="ufType" id="ufType">

      <xs:restriction base="xs:string">

      <xs:enumeration value="SP" />

      <xs:enumeration value="TO" />

      </xs:restriction>

      </xs:simpleType>

      <xs:simpleType name="codAutorizacaoType" id="codAutorizacaoType">

      <xs:restriction base="xs:string">

      <xs:pattern value="\d{0,20}" />

      </xs:restriction>

      </xs:simpleType>

      <xs:element name="root">

      <xs:complexType>

      <xs:sequence>

      <xs:element name="nrAutorizacoes" type="xs:integer" minOccurs="1" maxOccurs="1" />

      <xs:element name="autorizacoes" minOccurs="1" maxOccurs="1" type="autorizacoesType" />

      </xs:sequence>

      </xs:complexType>

      </xs:element>

      </xs:schema>

  • avatar image
    Former Member
    Dec 29, 2006 at 07:30 PM

    Rodrigo,

    I always put targetNameSpace field value in the XSD as the namespace you define in the SWC. Then it will work. I loaded your XSD with the changed target name space and it worked for me.

    --Archana

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Dec 30, 2006 at 10:25 AM

    Hi Rodrigo,

    please have a look at SAP note 901988. I think this will solve your problem.

    Greetings

    Stephan

    Add comment
    10|10000 characters needed characters exceeded