Message

Value MUST be part of code list 'Currency codes (ISO 4217)'.

Context
/ubl:DespatchAdvice/cac:Shipment/cac:TransportHandlingUnit/cac:Package/cac:ContainedPackage/cac:GoodsItem/cbc:DeclaredStatisticsValueAmount
Test
not(@currencyID) or (some $code in $clISO4217 satisfies $code = @currencyID)
Code lists
Currency codes (ISO 4217)
Usage
/ ubl:DespatchAdvice / cac:Shipment / cac:TransportHandlingUnit / cac:Package / cac:ContainedPackage / cac:GoodsItem / cbc:DeclaredStatisticsValueAmount / @currencyID