Skip to main content
Question

Show only the latest related Order number when a Quote has multiple Orders

  • July 9, 2026
  • 2 replies
  • 26 views

Forum|alt.badge.img+1

Hi team,

My Quote object can have multiple related Orders (child relationship). I only want to show the latest Order's OrderNumber in my Gen template — not all of them.

Is this possible, and if yes, how do I set it up?

Note: Refer to the screenshot.

Thanks!

2 replies

Forum|alt.badge.img+1
  • Author
  • Newcomer
  • July 10, 2026

@Michael.Rave ​@mshealy could you please take a look at this? I noticed you've already answered many of the questions. If someone else can answer instead, that's fine too, I’ll keep that in mind for future questions.


Michael.Rave
Docusign Employee
Forum|alt.badge.img+19
  • Docusign Employee
  • July 10, 2026

@As75 

Thank you for reaching out and tagging me.

I can image two ways of realising this by handling the Salesforce data you pass to Docusign Gen rather then trying to filter it out on the Word template.

1. Custom formula field on Quote (automated)

  • Create a custom text/number field on Quote, e.g. Latest_Order_Number__c.
  • Populate it with the related Order you consider “latest” (e.g. highest CreatedDate, or most recent Status change) using:
    • A Flow (Record-Triggered Flow on Order that updates the parent Quote), or
    • A small Apex trigger / batch if you already use Apex for CPQ logic.
  • In the Gen template, use Lates_Order_Number__c instead of traversing all Orders.

2. Custom lookup field on Quote (manual)

  • Create a custom “Latest Order” lookup field on Quote
  • Manually point to the latest Order before starting the document generation.
  • Have the Gen form/section target that lookup instead of the generic Orders__r relationship.

I hope this helps!