Skip to content

A script that emails an order report throws 'PrintJobContents: Field [Report_Id] with value XXX_REP is not a part of Print Job' — but the report ID being referenced looks correct, so what's actually wrong?

Answer

This error is a literal, accurate description of the underlying API: the PrintJobContents Logical Unit (backed by PRINT_JOB_CONTENTS_API) only has the fields PRINT_JOB_ID, INSTANCE_SEQ, RESULT_KEY, and INSTANCE_ATTR — there's no REPORT_ID field on it at all. The actual bug is almost always in the calling script: a REPORT_ID name-value pair is being added into the attribute string that gets passed to PrintJobContents specifically, when that attribute belongs on a different API/LU in the flow instead. Check exactly which attribute string in your script is receiving the REPORT_ID pair and correct which API call it's actually being passed to.

← Browse Reporting and analytics questions