Rules / IBR-122-AE
IBR-122-AE error
When Invoice type code is 'Out of scope of VAT' or 'Credit note related to goods or…
When Invoice type code (IBT-003) is 'Out of scope of VAT' or 'Credit note related to goods or services', then the Document level allowance VAT category code (IBT-095), Document level charge VAT category code (IBT-102), Invoiced item VAT category code (IBT-151) must be either 'Exempt from VAT' and/or 'Not subject to VAT' and/or 'Zero rated'.
Fails
<cbc:InvoiceTypeCode>81</cbc:InvoiceTypeCode>
<!-- the data this document type requires is missing or wrong -->
Fix
Type code 81 triggers this rule. Add what it asks for, or check the type code is right.
Schematron
- Context
/ubl:Invoice | /cn:CreditNote- Test
not((cbc:InvoiceTypeCode | cbc:CreditNoteTypeCode) = "81" or (cbc:InvoiceTypeCode | cbc:CreditNoteTypeCode) = "480") or (every $cat in (//cac:TaxCategory/cbc:ID | //cac:ClassifiedTaxCategory/cbc:ID) satisfies normalize-space($cat) = ("E","O","Z"))
Official text: When Invoice type code (IBT-003) is 'Out of scope of VAT' or 'Credit note related to goods or services', then the Document level allowance VAT category code (IBT-095), Document level charge VAT category code (IBT-102), Invoiced item VAT category code (IBT-151) MUST be either 'Exempt from VAT' and/or 'Not subject to VAT' and/or 'Zero rated'.