At most one ram:ID for the invoicee

Error FX-SCH-A-000864 Factur-X

Element 'ram:ID' 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:ID occurs more than once in ram:InvoiceeTradeParty. This element may appear there at most once.

What the rule means

The limit ensures that the invoicee is not represented by multiple entries in the same identification element.

Please use no more than one `ram:ID` for the invoicee

The invoicee contains multiple ram:ID elements. Keep no more than one in this entry.

What to do
  1. Find ram:InvoiceeTradeParty in the invoice.
  2. Remove the extra ram:ID elements so that no more than one remains.
  3. Generate the invoice again and validate it once more.
What it looks like
✗ Triggers the message
<ram:InvoiceeTradeParty>
  <ram:ID>A</ram:ID>
  <ram:ID>B</ram:ID>
</ram:InvoiceeTradeParty>
✓ Correct
<ram:InvoiceeTradeParty>
  <ram:ID>A</ram:ID>
</ram:InvoiceeTradeParty>
Technical details

The test counts the direct ram:ID elements in ram:InvoiceeTradeParty and requires a count of no more than one.

Where the rule applies

The rule applies to ram:ID within ram:InvoiceeTradeParty, the invoicee.

Context (rule/@context)
/rsm:CrossIndustryInvoice/rsm:SupplyChainTradeTransaction/ram:ApplicableHeaderTradeSettlement/ ram:InvoiceeTradeParty
Test expression (assert/@test)
count(ram:ID)<=1