[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]
Subject: More code list questions about NDR, and about genericode
Work is progressing well, but I've hit a snag not realizing naming and design rules about the naming of metadata properties for code list values. So far it would appear my value checking is working entirely when I don't consider versioning of the code lists. Then after this is when I trip over NDR questions. Take, for example, in Order, the following three information items from UBL 1.0 Order and their associated code list meta data attributes: @amountCurrencyID (Item 15.2), @quantityUnitCode (Item 16.1), and cac:CountrySubentityCode (Item 63): 15 /po:Order/cbc:LineExtensionTotalAmount 15.1 /po:Order/cbc:LineExtensionTotalAmount/@amountCurrencyCodeListVersionID 15.2 /po:Order/cbc:LineExtensionTotalAmount/@amountCurrencyID 16 /po:Order/po:TotalPackagesQuantity 16.1 /po:Order/po:TotalPackagesQuantity/@quantityUnitCode 16.2 /po:Order/po:TotalPackagesQuantity/@quantityUnitCodeListAgencyID 16.3 /po:Order/po:TotalPackagesQuantity/@quantityUnitCodeListAgencyName 16.4 /po:Order/po:TotalPackagesQuantity/@quantityUnitCodeListID 63 /po:Order/cac:BuyerParty/cac:Party/cac:Address/cac:CountrySubentityCode 63.1 /po:Order/cac:BuyerParty/cac:Party/cac:Address/cac:CountrySubentityCode/@codeListAgencyID 63.2 /po:Order/cac:BuyerParty/cac:Party/cac:Address/cac:CountrySubentityCode/@codeListAgencyName 63.3 /po:Order/cac:BuyerParty/cac:Party/cac:Address/cac:CountrySubentityCode/@codeListID 63.4 /po:Order/cac:BuyerParty/cac:Party/cac:Address/cac:CountrySubentityCode/@codeListName 63.5 /po:Order/cac:BuyerParty/cac:Party/cac:Address/cac:CountrySubentityCode/@codeListSchemeURI 63.6 /po:Order/cac:BuyerParty/cac:Party/cac:Address/cac:CountrySubentityCode/@codeListURI 63.7 /po:Order/cac:BuyerParty/cac:Party/cac:Address/cac:CountrySubentityCode/@codeListVersionID 63.8 /po:Order/cac:BuyerParty/cac:Party/cac:Address/cac:CountrySubentityCode/@languageID 63.9 /po:Order/cac:BuyerParty/cac:Party/cac:Address/cac:CountrySubentityCode/@name My quandary is figuring out the automation of which code list attributes are to be tested for which information items based on codes. (1) why does @amountCurrencyID have only @amountCurrencyCodeListVersionID and not others such as @amountCurrencyCodeListAgencyName? (2) why doesn't @quantityUnitCode have @quantityUnitCodeListAgencyName and not others such as @quantityUnitCodeListVersionID? (3) why don't the meta data attributes of CountrySubentityCode have any prefix at all and just have "@codeListName"? (4) why do I use only "amountCurrency" when prefixing "CodeListVersionID", as contrasted with using "quanityUnit" when prefixing "CodeListAgencyID" ... is the rule I remove the last "ID" or "Code" from the information item name before adding the suffix? I've looked in NDR Section 6 of cd-UBL-NDR-1.0Rev1b.pdf under "Code Lists" without any clues to the answers to the above questions. And compare UBL meta data with identification fields from a sample genericode file: <Identification> <ShortName/> <LongName>ISO 4217 Alpha</LongName> <Version>0.4</Version> <CanonicalUri>urn:oasis:names:specification:ubl:schema:xsd:CurrencyCode</CanonicalUri> <CanonicalVersionUri>urn:oasis:names:specification:ubl:schema:xsd:CurrencyCode-1.0</CanonicalVersionUri> </Identification> I note five identification items in genericode, so I assume I map them as follows: genericode ShortName == UBL xxxxxCodeListID genericode LongName == UBL xxxxxCodeListName genericode Version == UBL xxxxxCodeListVersionID genericode CanonicalUri == UBL xxxxxCodeListURI genericode CanonicalVersionUri == UBL xxxxxCodeListSchemeURI Tony, can you confirm this is all of the version checking that I need to do when using a genericode file to express the values in a UBL instance? My methodology has been to respect code list meta data attributes when present, matching them with genericode items when present, and accepting values without checking meta data properties when either a particular meta data attribute is not present or a particular genericode identification field is not present. My problem is now down to the naming of the meta data attributes. Would the following be acceptable? (1) for @xxxxxID remove "ID" and suffix with "Code..." from genericode table above as appropriate (2) for @xxxxxCode remove "Code" and suffix with "Code..." from genericode table above as appropriate (3) for <xxxxx> suffix with "code..." from genericode table above as appropriate Unfortunately, this introduces my need to know if the XPath address given by the user is addressing an element or an attribute (which is not at all straightforward when examining the infinite XPath address syntax for clues). Thanks for help with these answers so that I can progress. . . . . . . . . . Ken -- World-wide on-site corporate, govt. & user group XML/XSL training. G. Ken Holman mailto:gkholman@CraneSoftwrights.com Crane Softwrights Ltd. http://www.CraneSoftwrights.com/o/ Box 266, Kars, Ontario CANADA K0A-2E0 +1(613)489-0999 (F:-0995) Male Cancer Awareness Aug'05 http://www.CraneSoftwrights.com/o/bc Legal business disclaimers: http://www.CraneSoftwrights.com/legal
[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]