At most one industry-assigned ID

Error FX-SCH-A-000343 Factur-X

Element 'ram:IndustryAssignedID' 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

A referenced product contains more than one ram:IndustryAssignedID element. This element may occur at most once within ram:IncludedReferencedProduct.

What the rule means

The structure allows at most one industry-assigned ID for each referenced product. Multiple identifiers in this place do not match the required XML structure.

Please provide at most one industry-assigned ID for each referenced product

ram:IndustryAssignedID appears more than once for a referenced product. You can adjust the entry so that it contains at most one industry-assigned ID.

What to do
  1. Locate the affected ram:IncludedReferencedProduct.
  2. Remove any extra ram:IndustryAssignedID elements so that at most one remains.
  3. Regenerate the invoice and check it again.
What it looks like
✗ Triggers the message
<ram:IncludedReferencedProduct>
  <ram:IndustryAssignedID>A</ram:IndustryAssignedID>
  <ram:IndustryAssignedID>B</ram:IndustryAssignedID>
</ram:IncludedReferencedProduct>
✓ Correct
<ram:IncludedReferencedProduct>
  <ram:IndustryAssignedID>A</ram:IndustryAssignedID>
</ram:IncludedReferencedProduct>
Technical details

The rule counts the direct ram:IndustryAssignedID elements in the context of ram:IncludedReferencedProduct and allows zero or one.

Where the rule applies

The rule applies to ram:IndustryAssignedID within a referenced product (ram:IncludedReferencedProduct) on an invoice line.

Context (rule/@context)
/rsm:CrossIndustryInvoice/rsm:SupplyChainTradeTransaction/ram:IncludedSupplyChainTradeLineItem/ ram:SpecifiedTradeProduct/ram:IncludedReferencedProduct
Test expression (assert/@test)
count(ram:IndustryAssignedID)<=1