Provide the line total basis no more than once

Error FX-SCH-A-000323 Factur-X

Element 'ram:LineTotalBasisAmount' 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:LineTotalBasisAmount may occur no more than once in ram:ApplicableTradeTax. The rule fails if the element occurs more than once.

What the rule means

ram:LineTotalBasisAmount identifies the total of the invoice lines as part of the VAT breakdown. Multiple occurrences would repeat this value.

Please provide the line total basis no more than once

ram:LineTotalBasisAmount appears more than once in the VAT breakdown. You can resolve this by removing duplicate occurrences.

What to do
  1. Locate the relevant ram:ApplicableTradeTax.
  2. Check how many ram:LineTotalBasisAmount elements it contains.
  3. Remove any extra occurrences so that no more than one remains.
  4. Generate the invoice again and validate it once more.
Technical details

The XPath test count(ram:LineTotalBasisAmount)<=1 allows zero or one direct child element and disallows multiple occurrences.

Where the rule applies

The rule applies to each ram:ApplicableTradeTax in the document-level VAT breakdown.

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