BR-RO-170
Daca Codul tarii Reprezentantului fiscal al Vanzatorului (BT-69) este RO, atunci Subdiviziunea tarii Reprezentantului fiscal al Vanzatorului (BT-68) trebuie sa fie codificata folosind lista de coduri ISO 3166-2:RO (ex. RO-B pentru Municipiul Bucuresti, RO-AB pentru judetul Alba...). #If the Seller's tax representative country code (BT-69) is RO, then the Seller's tax representative country subdivision (BT-68) must be coded using the ISO 3166-2: RO code list (ex. RO-B for Bucharest, RO-AB for Alba County...).
What the rule checks
As the rule set's publisher wrote it. The rule runs on every element the context matches, and fails where the test is false; the validator reports the line of that element.
/ubl:Invoice/cac:TaxRepresentativeParty/cac:PostalAddress | /ubl:CreditNote/cac:TaxRepresentativeParty/cac:PostalAddress
normalize-space(cac:Country/cbc:IdentificationCode) = 'RO' and not(normalize-space(cbc:CountrySubentity) = $ISO-3166-RO-CODES)
Checked with Romania RO e-Factura Invoice (UBL), Romania RO e-Factura Credit Note (UBL)