SAP Knowledge Base Article - Public

2491086 - Document is not generated - placeholders with multiple values error

Symptom

An application error is received when generating a document.

Error: The document cannot be generated as the following placeholders with multiple values in the same row are mapped to different base objects.

Image/data in this KBA is from SAP internal systems, sample data, or demo systems. Any resemblance to real data is purely coincidental. 

Environment

Employee Central - Document Generation

Reproducing the Issue

  1. Go to "Generate Document."
  2. Select the template Employment_Of_Contract_Expats.
  3. Select the employee name 
  4. Select the "As of date" 
  5. Generate the template.
  6. An error : The document cannot be generated as the following placeholders with multiple values in the same row are mapped to different base object

Example: An error pops-up similar to below:

Capture.jpg

Note: here, in above sample error, the fields shown are the ones having issues. These fields might be different based on instance specific configuration.

Cause

The error is self explanatory. In our sample case, the issue was:

  • Tokens mapped to addresses are returning multiple values (most probably because the user has multiple addresses maintained). That is why only those tokens are showed in the error dialog.
  • This error occurs when multiple placeholders, each mapped to different base objects, are added in the same table row within the template body.
  • Additionally, multiple values are maintained for these placeholders for a user.

Resolution

Possible solutions are:

  1. Move the placeholders outside the table. Once they're outside, the system resolves these placeholders using the first value if multiple values are returned for a user.
  2. Remove the tokens mapped to Addresses as they seem to be returning multiple values.
  3. Use a rule mapping for the fields of Addresses so that you fetch a single address instead of all the available ones.

Kindly apply the same logic where a mapping can return multiple values.

FAQ - Additional Information

Q) Where can I get information on this from the Guide?

 A) Guide:Implementing Document Generation                                                                                                                                                             Chapter: Troubleshooting Tips

See Also

  • 2347226 - Employee Central Implementation - Document Generation FAQ
  • 3042197 - EC: Document generation rule to display HR Manager phone number
  • 3420641 - Past Direct Mapping from a MDF Object in Document Generation
  • 2742128 - How to display "As Of Date" value in a Document Generation?

Keywords

Incident , INC11402562,The document cannot be generated as the following placeholders with multiple values in the same row are mapped to different base object, document ,placeholders, document generate, error, multiple placeholders , KBA , LOD-SF-EC-DOC , Document Generation , LOD-SF-EC , Employee Central , Problem

Product

SAP SuccessFactors HCM Core 1705