Use an allowed format value for the order date

Error FX-SCH-A-000785 Factur-X

Value of '@format' 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 value of format on qdt:DateTimeString is not listed as an allowed value in code list 17. An empty value is also accepted by this test.

What the rule means

Code list 17 limits the allowed format values for the date and provides a consistent classification.

Please use an allowed format value for the order date

The value of format on qdt:DateTimeString in the order reference is not allowed. Use a value from the specified code list.

What to do
  1. Check the value of format on qdt:DateTimeString in the order reference.
  2. Replace any disallowed value with a value listed in code list 17.
  3. Regenerate the invoice and validate it again.
Technical details

The test accepts an empty $codeValue17 value or a value listed in code list ID 17 in FACTUR-X_EXTENDED_codedb.xml.

Where the rule applies

The rule applies to the format attribute of qdt:DateTimeString within the date of the ultimate customer order reference.

Context (rule/@context)
/rsm:CrossIndustryInvoice/rsm:SupplyChainTradeTransaction/ram:ApplicableHeaderTradeAgreement/ ram:UltimateCustomerOrderReferencedDocument/ram:FormattedIssueDateTime/ qdt:DateTimeString
Test expression (assert/@test)
string-length($codeValue17)=0 or document('FACTUR-X_EXTENDED_codedb.xml')/codedb/cl[@id=17]/enumeration[@value=$codeValue17]