VRBL-DPA-MX-1p0-75

Basic Info

Rule The %{cbc:GrossWeightMeasure/@unitCode} and the %{cbc:NetWeightMeasure/@unitCode} must match when provided.
Context /ubl:DespatchAdvice/cac:Shipment
Pattern vrbl-despatchadvice-mx-1p0
Severity fatal

Implementation

				not(
                    boolean(cbc:GrossWeightMeasure/@unitCode)
                    and
                    boolean(cbc:NetWeightMeasure/@unitCode)
                )
                or
                cbc:GrossWeightMeasure/@unitCode = cbc:NetWeightMeasure/@unitCode