Rules
Basic Info
|
Rule
|
The Unique Unit ID must be a valid UUID. |
|
Context
|
/ubl:Invoice/cbc:UUID
|
|
Pattern
|
vrbl-invoice-tr-1p2 |
|
Severity
|
fatal |
Used Template: IsUUID
| Parameter |
|
Value |
| probe |
= |
.
|
Implementation
not(boolean(.))
or
(
string-length(.) = 36
and translate(substring(., 1, 8), '0123456789abcdefABCDEF', '') = ''
and substring(., 9, 1) = '-'
and translate(substring(., 10, 4), '0123456789abcdefABCDEF', '') = ''
and substring(., 14, 1) = '-'
and translate(substring(., 15, 4), '0123456789abcdefABCDEF', '') = ''
and substring(., 19, 1) = '-'
and translate(substring(., 20, 4), '0123456789abcdefABCDEF', '') = ''
and substring(., 24, 1) = '-'
and translate(substring(., 25, 12), '0123456789abcdefABCDEF', '') = ''
)