BR-KSA-88: Exchange-rate source currency must equal the invoice currency
If cac:TaxExchangeRate/cbc:SourceCurrencyCode (KSA-37) is present and non-empty, it must match cbc:DocumentCurrencyCode (BT-5).
How to fix it
Put the same code as cbc:DocumentCurrencyCode in cac:TaxExchangeRate/cbc:SourceCurrencyCode (e.g. USD in both).
ZATCA's official text
[BR-KSA-88] If exist, Source Currency Code (KSA-37) must be the same as Invoice currency code (BT-5)
Source: ZATCA SDK 3.4.8 · ZATCA KSA rules
Fails when (the condition ZATCA's SDK runs)
exists(/ubl:Invoice/cac:TaxExchangeRate/cbc:SourceCurrencyCode) and (/ubl:Invoice/cac:TaxExchangeRate/cbc:SourceCurrencyCode) != '' and not(matches(normalize-space(//cbc:DocumentCurrencyCode), /ubl:Invoice/cac:TaxExchangeRate/cbc:SourceCurrencyCode) and (/ubl:Invoice/cac:TaxExchangeRate/cbc:SourceCurrencyCode !='') )
Related rules
- BR-05 · Every invoice needs a currency code (BT-5)
- BR-KSA-87 · Tax exchange rate needs source currency, target currency and rate
- BR-KSA-97 · Non-SAR invoice: SAR VAT total must differ from the VAT total
- BR-KSA-CL-01 · Invoice currency code must be a valid ISO 4217 code
- BR-KSA-CL-02 · Every amount's currencyID must match the invoice currency
Validate your invoice against ZATCA's rules
Paste the XML and see every error and warning. It runs in your browser; the invoice goes nowhere.
Validate an invoice or try Matheel