At most one consignor identifier

Error FX-SCH-A-000794 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 appears more than once in ram:ShipFromTradeParty. The test allows this element at most once.

What the rule means

The limit ensures that multiple identifiers are not supplied for the consignor using this same element.

Please use no more than one `ram:ID` in `ram:ShipFromTradeParty`

ram:ID has been provided more than once for the consignor. This element may appear no more than once in this section.

What to do
  1. Find ram:ShipFromTradeParty in the delivery details.
  2. Check the ram:ID elements it contains and remove any extra occurrences.
  3. Generate the invoice again and validate it once more.
What it looks like
✗ Triggers the message
<ram:ShipFromTradeParty>
  <ram:ID>ABC</ram:ID>
  <ram:ID>DEF</ram:ID>
</ram:ShipFromTradeParty>
✓ Correct
<ram:ShipFromTradeParty>
  <ram:ID>ABC</ram:ID>
</ram:ShipFromTradeParty>
Technical details

The XPath test counts the direct ram:ID elements within ram:ShipFromTradeParty and requires the count to be no greater than one.

Where the rule applies

The rule applies to ram:ID within ram:ShipFromTradeParty, the party from which the goods are shipped.

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