At most one global buyer identifier

Error FX-SCH-A-000164 Factur-X

Element 'ram:GlobalID' may occur at maximum 1 times.

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

ram:BuyerTradeParty contains more than one direct ram:GlobalID element. At most one global identifier is allowed for the buyer.

What the rule means

The rule limits the number of global buyer identifiers at this location to one at most.

Please use no more than one global buyer identifier

The buyer record contains multiple global ram:GlobalID identifiers. You can resolve this by leaving no more than one such element there.

What to do
  1. Find ram:BuyerTradeParty.
  2. Remove any extra ram:GlobalID elements from it.
  3. Generate the invoice again and validate it.
What it looks like
✗ Triggers the message
<ram:BuyerTradeParty>
  <ram:GlobalID/>
  <ram:GlobalID/>
</ram:BuyerTradeParty>
✓ Correct
<ram:BuyerTradeParty>
  <ram:GlobalID/>
</ram:BuyerTradeParty>
Technical details

Within ram:BuyerTradeParty, the number of direct ram:GlobalID elements is checked to be no greater than one.

Where the rule applies

The rule applies to ram:GlobalID elements within ram:BuyerTradeParty.

Context (rule/@context)
/rsm:CrossIndustryInvoice/rsm:SupplyChainTradeTransaction/ram:ApplicableHeaderTradeAgreement/ ram:BuyerTradeParty
Test expression (assert/@test)
count(ram:GlobalID)<=1