VRBL-WBL-IN-1p0-8
Basic Info
|
Rule
|
The value of the Shipment Delivery Location Country Subentity Code must be contained in State Code (defined by GST) [VRBL-CL-IN-CountrySubentityCode] (prefixed by 'VRBL:IN:'). |
|
Context
|
/ubl:Waybill/cac:Shipment/cac:Delivery/cac:DeliveryLocation/cac:Address/cbc:CountrySubentityCode
|
|
Pattern
|
vrbl-waybill-in-1p0 |
|
Severity
|
fatal |
Used Template: CodeList
| Parameter |
|
Value |
| probe |
= |
.
|
| codeList |
= |
$VRBL-IN-Prefix:$VRBL-CL-IN-CountrySubentityCode
|
Implementation
not(boolean(.))
or
(
(
substring(normalize-space(.), 1, string-length($VRBL-IN-Prefix)) = $VRBL-IN-Prefix
and
not(
contains(
substring-after(normalize-space(.), $VRBL-IN-Prefix),
substring($VRBL-CL-IN-CountrySubentityCode, 1, 1)
)
)
and
contains(
$VRBL-CL-IN-CountrySubentityCode,
concat(
substring($VRBL-CL-IN-CountrySubentityCode, 1, 1),
substring-after(normalize-space(.), $VRBL-IN-Prefix),
substring($VRBL-CL-IN-CountrySubentityCode, 1, 1)
)
)
)
)