Message

The VAT identifier for the supplier SHOULD be prefixed with country code.

Context
//cac:AccountingSupplierParty
Test
not(/ubl:CreditNote/cac:TaxTotal/*/*/*/cbc:ID = 'VAT') or (some $companyID in cac:Party/cac:PartyTaxScheme/cbc:CompanyID satisfies (starts-with($companyID,cac:Party/cac:PostalAddress/cac:Country/cbc:IdentificationCode)))
Usage
/ ubl:CreditNote / cac:AccountingSupplierParty / cac:Party / cac:PartyTaxScheme / cbc:CompanyID