Not all filename attributes of the embeddedDocumentBinaryObject elements are unique
At least two ram:AdditionalReferencedDocument elements use the same value in the filename attribute of their ram:AttachmentBinaryObject. The embedded document filenames are therefore not unique.
A unique filename distinguishes embedded documents from one another. The rule requires filenames of referenced documents not to be reused.
At least two embedded documents in your invoice have the same filename. Change the duplicate names so that each document has its own filename.
- Check the
filenameattributes of theram:AttachmentBinaryObjectelements. - Compare the filenames in all
ram:AdditionalReferencedDocumentelements. - Change each duplicate filename.
- Generate the invoice again and validate it once more.
<ram:AdditionalReferencedDocument> <ram:AttachmentBinaryObject filename="document.pdf">...</ram:AttachmentBinaryObject> </ram:AdditionalReferencedDocument> <ram:AdditionalReferencedDocument> <ram:AttachmentBinaryObject filename="document.pdf">...</ram:AttachmentBinaryObject> </ram:AdditionalReferencedDocument>
<ram:AdditionalReferencedDocument> <ram:AttachmentBinaryObject filename="document-1.pdf">...</ram:AttachmentBinaryObject> </ram:AdditionalReferencedDocument> <ram:AdditionalReferencedDocument> <ram:AttachmentBinaryObject filename="document-2.pdf">...</ram:AttachmentBinaryObject> </ram:AdditionalReferencedDocument>
Technical details
The test compares the count of all ram:AdditionalReferencedDocument elements with the count of elements whose filename does not match that of a preceding sibling ram:AdditionalReferencedDocument.
The rule applies to all ram:AdditionalReferencedDocument elements and their embedded files in the invoice.
rule/@context)assert/@test)