# PEPPOL-EN16931-R121

Source: https://xmlvalid.com/rules/PEPPOL-EN16931-R121

> Base quantity MUST be a positive number above zero.

- Level: error
- Rule sets: Peppol BIS Billing 3.0 rules 3.0.21, XRechnung 3.0 rules (UBL) 2.6.0
- Context: `cac:InvoiceLine | cac:CreditNoteLine`
- Test: `not(cac:Price/cbc:BaseQuantity) or xs:decimal(cac:Price/cbc:BaseQuantity) > 0`

> Base quantity MUST be a positive number above zero.

- Level: error
- Rule sets: XRechnung 3.0 rules (CII) 2.6.0
- Context: `ram:NetPriceProductTradePrice | ram:GrossPriceProductTradePrice`
- Test: `not(ram:BasisQuantity) or xs:decimal(ram:BasisQuantity) > 0`

## Why it fails

- `cac:Price/cbc:BaseQuantity` is 0 or negative.

## How to fix it

- Leave the base quantity out (it then counts as 1), or give the quantity the price is for, such as `100` for a price per hundred.

Validate a document against these rules: https://xmlvalid.com/validate
