MHonArc v2.5.2 -->
ubl-ndrsc message
[Date Prev]
| [Thread Prev]
| [Thread Next]
| [Date Next]
--
[Date Index]
| [Thread Index]
| [Elist Home]
Subject: RE: [ubl-ndrsc] Code lists: discussion kickoff
Title: RE: [ubl-ndrsc] Code lists: discussion kickoff
Certainly:
I have an "Identifier" type, which has two fields: a string, which is the value of the identifier, and a code, which tells me which standard ID scheme is used - that is, which Agency defines the identifier value's meaning. For example, I have a DUNS (Dun & Bradstreet) number, a common scheme for identifying company organizations. (The sample is a tiny subset of the list from xCBL).
<complexType name="Identifier">
<element name="IDNumber" type="string"/>
<element name="AgencyIDCode" type="AgencyCode"/>
</complexType>
<simpleType name="AgencyCode">
<restriction base="NMTOKEN">
<xsd:enumeration value="DIN"/>
<xsd:enumeration value="DirectionGeneraleDesDouanesEtDroitsIndirects"/>
<xsd:enumeration value="DistrictOfColumbia"/>
<xsd:enumeration value="DK"/>
<xsd:enumeration value="DK-EAN"/>
<xsd:enumeration value="DK-MHA"/>
<xsd:enumeration value="DK-NBH"/>
<xsd:enumeration value="DK-PBS"/>
<xsd:enumeration value="DunAndBradstreet"/>
<xsd:enumeration value="EAN"/>
</restriction>
</simpleType>
So, the field AgencyIDCode has a value of AgencyCode, which allows us to maintain a list of valid values in the schema.
For complete examples, look at the PartySample.xsd I sent out before the F2F - this has about 4 or 5 codelists in it, all handled exactly this way.
Cheers,
Arofan