SAP Knowledge Base Article - Public

3793055 - Error message: "Error(s) occurred when merging the document. The return code is 101." while preview the document from 'Manage Preliminary Billing Documents' app- SAP S/4HANA Cloud Public Edition

Symptom

Error message "Error(s) occurred when merging the document. The return code is 101." occurs when previewing a billing document, preventing the document and attachments from being displayed in "Manage Preliminary Billing Documents" app.

Environment

SAP S/4HANA Cloud Public Edition

Reproducing the Issue

  1. Open the "Manage Preliminary Billing Documents" app.
  2. Open a preliminary billing document.
  3. Preview button.
  4. Observe the error: "Error(s) occurred when merging the document. The return code is 101."

Cause

Output Control uses API CL_RSPO_PDF_MERGE for PDF merge API. Return code (RC) 101 means "Invalid Document".

Resolution

  1. Identify the billing document attachments and check the PDF versions.
  2. If any attachment is PDF version 2.0, convert it to a lower PDF version (for example 1.7 or 1.5).
  3. Re-upload the converted PDF attachment to the billing document.
  4. Retry the preview of the billing document.
  5. If the error persists, verify that all attachments are valid, non-corrupted PDFs and repeat steps 2–4 for any remaining version 2.0 files.

See Also

  • KBA 3367875 - Merging issue with billing document attachments - SAP S/4HANA Cloud Public Edition.
  • KBA 3453127- ‘Error(s) occurred when merging the document. The return code is 107’ in purchase order output.

Keywords

billing document preview, output control, attachments merge, pdf merge, return code 101, invalid document, CL_RSPO_PDF_MERGE, preview error, preliminary billing document, attachment error, pdf version, merge failure, BC-CCM-PRN-SPO, rc 101, output management , KBA , BC-CCM-PRN-SPO , Spool System , Problem

Product

SAP S/4HANA Cloud Public Edition all versions