Decimal places in the allowance base amount

Error BR-DEC-02 EN 16931

The allowed maximum number of decimals for the Document level allowance base amount (BT-93) is 2.

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

The amount in ram:BasisAmount has more than two digits after the decimal separator.

What the rule means

The base amount for the document level allowance may have no more than two decimal places. This keeps the stated calculation base within the permitted precision.

Affected fields BT-93
Please limit the decimal places in the allowance base amount

The allowance base amount has more than two decimal places. Adjusting the amount will resolve this formatting issue.

What to do
  1. Check the value in the allowance’s ram:BasisAmount.
  2. Limit the amount to no more than two decimal places.
  3. Check the BasisAmount property.
  4. Regenerate the invoice and validate it again.
What it looks like
✗ Triggers the message
<ram:SpecifiedTradeAllowanceCharge>
  <ram:ChargeIndicator>
    <udt:Indicator>false</udt:Indicator>
  </ram:ChargeIndicator>
  <ram:BasisAmount>10.123</ram:BasisAmount>
</ram:SpecifiedTradeAllowanceCharge>
✓ Correct
<ram:SpecifiedTradeAllowanceCharge>
  <ram:ChargeIndicator>
    <udt:Indicator>false</udt:Indicator>
  </ram:ChargeIndicator>
  <ram:BasisAmount>10.12</ram:BasisAmount>
</ram:SpecifiedTradeAllowanceCharge>
Check in FactoorSharp
  • AbstractTradeAllowanceCharge.BasisAmount (Document level allowance: BT-93)
Technical details

The check counts the characters after the decimal point in ram:BasisAmount of the parent ram:SpecifiedTradeAllowanceCharge and allows no more than two.

Where the rule applies

The rule applies to ram:BasisAmount of an allowance in ram:SpecifiedTradeAllowanceCharge within ram:ApplicableHeaderTradeSettlement.

Context (rule/@context)
//ram:ApplicableHeaderTradeSettlement/ram:SpecifiedTradeAllowanceCharge/ram:ChargeIndicator[udt:Indicator='false']
Test expression (assert/@test)
string-length(substring-after(../ram:BasisAmount,'.'))<=2