Use an allowed scheme identifier value for the buyer identifier

Error FX-SCH-A-000697 Factur-X

Value of '@schemeID' is not allowed.

Mandatory rule: As long as it is violated, the invoice is invalid and will be rejected by validators.
What is wrong

The value of schemeID on GlobalID is not empty and does not match any value allowed by this rule. The check compares the value with the enumeration under codedb/cl with identifier 11 in FACTUR-X_EXTENDED_codedb.xml.

What the rule means

The rule restricts the scheme identifier for the buyer’s global identifier to values from the corresponding enumeration.

Please use an allowed value for the buyer identifier’s scheme identifier

The value of schemeID on GlobalID is not accepted by this rule. You can change it to one of the values permitted for this field.

What to do
  1. Find GlobalID in BuyerTradeParty and read the value of schemeID.
  2. Compare the value with the enumeration cl with identifier 11 in FACTUR-X_EXTENDED_codedb.xml and use only a value listed there.
  3. Generate the invoice again and validate it.
Technical details

The test accepts an empty value or a value present in the enumeration with cl identifier 11 in FACTUR-X_EXTENDED_codedb.xml.

Where the rule applies

The rule applies to the value of the schemeID attribute on GlobalID in the buyer details BuyerTradeParty.

Context (rule/@context)
/rsm:CrossIndustryInvoice/rsm:SupplyChainTradeTransaction/ram:ApplicableHeaderTradeAgreement/ ram:BuyerTradeParty/ram:GlobalID
Test expression (assert/@test)
string-length($codeValue11)=0 or document('FACTUR-X_EXTENDED_codedb.xml')/codedb/cl[@id=11]/enumeration[@value=$codeValue11]