Dati XML di esempio che contengono i parametri MQRFH2:
<?xml version="1.0" encoding="UTF-8"?>
<NameValueData>
<parameterA>
<property1>value</property1>
<property2 datatype="nt">345</property2>
</parameterA>
<parameterB>
<groupHeader>
<property3>true</property3>
</groupHeader>
<groupDtl>
<property4>ANR</property4>
<property4>BYC</property4>
<property4>ENN</property4>
</groupDtl>
</parameterB>
<parameterC>
<groupNew>
<property5>01/15/2004</property5>
</groupNew>
<property1>value</property1>
</parameterC>
</NameValueData>
Il seguente schema XML di esempio definisce i tre parametri precedentemente visualizzati in Dati XML di esempio contenenti i parametri MQRFH2. Il tipo per tutti gli elementi proprietà: MQRFH2PropertyType, fornisce l'attributo datatype (tipo di dati) mostrato in property2 nel precedente esempio di dati XML. Inoltre, il tipo MQRFH2PropertyType assicura che gli elementi possono contenere dei valori.
La ripetizione di property4 in groupDtl è gestita mediante gli attributi minOccurs e maxOccurs. È inoltre possibile impostare per maxOccurs il valore unbounded per consentire un numero illimitato di ripetizioni.
Uno schema XML di esempio che definisce i parametri MQRFH2:
<xsd:schema elementFormDefault="qualified"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:rfh="http://www.approuter.com/samples/MQ"
targetNamespace="http://www.approuter.com/samples/MQ">
<xsd:complexType name="MQRFH2PropertyType">
<xsd:simpleContent>
<xsd:extension base="xsd:string">
<xsd:attribute name="dt" type="xsd:string" use="optional"/>
</xsd:extension>
</xsd:simpleContent>
</xsd:complexType>
<xsd:element name="NameValueData">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="parameterA">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="property1" type="rfh:MQRFH2PropertyType"/>
<xsd:element name="property2" type="rfh:MQRFH2PropertyType"/>
</xsd:sequence>
</xsd:complexType>
</xsd:element>
<xsd:element name="parameterB">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="groupHeader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="property3" type="rfh:MQRFH2PropertyType"/>
</xsd:sequence>
</xsd:complexType>
</xsd:element>
<xsd:element name="groupDtl">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="property4" type="rfh:MQRFH2PropertyType" minOccurs="1"
maxOccurs="5"/>
</xsd:sequence>
</xsd:complexType>
</xsd:element>
</xsd:sequence>
</xsd:complexType>
</xsd:element>
<xsd:element name="parameterC">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="groupNew">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="property5" type="rfh:MQRFH2PropertyType"/>
</xsd:sequence>
</xsd:complexType>
</xsd:element>
<xsd:element name="property1" type="rfh:MQRFH2PropertyType"/>
</xsd:sequence>
</xsd:complexType>
</xsd:element>
</xsd:sequence>
</xsd:complexType>
</xsd:element>
</xsd:schema>