Allowed value for ram:LineStatusCode

Error FX-SCH-A-000334 Factur-X

Value of 'ram:LineStatusCode' is not allowed.

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

The non-empty value of ram:LineStatusCode is not included in the code list specified for this code.

What the rule means

If provided, the status code must conform to the specified code list. This check permits an empty value.

Please use an allowed status code for the invoice line

The value in ram:LineStatusCode is not listed as an allowed status code. If you provide a value, it must belong to the specified code list.

What to do
  1. Check the value in ram:LineStatusCode.
  2. Compare the non-empty value with the values allowed for this status code.
  3. Regenerate the invoice and check it again.
Technical details

The test permits an empty value or requires the value to be listed in FACTUR-X_EXTENDED_codedb.xml in the code list with identifier 6.

Where the rule applies

The rule applies to ram:LineStatusCode on the document associated with an invoice line.

Context (rule/@context)
/rsm:CrossIndustryInvoice/rsm:SupplyChainTradeTransaction/ram:IncludedSupplyChainTradeLineItem/ ram:AssociatedDocumentLineDocument/ram:LineStatusCode
Test expression (assert/@test)
string-length($codeValue6)=0 or document('FACTUR-X_EXTENDED_codedb.xml')/codedb/cl[@id=6]/enumeration[@value=$codeValue6]