Skip to content Skip to main navigation Skip to footer

Conditional Table Merge for Related List Items

Example Use Case:
An invoice is going to be generated from the Opportunity object, and it will include the OpportunityLineItems, however, we’d like to show sets of opportunity line items in the invoice.

You can create a table for each product category to merge the OppLineItem related list and create a filter of that related list based on your condition. Then build a separate table to merge another related list of OppLineItem that would have a different condition.

If you are merging from a record that has no values to merge and you do not want the table or title of table to be visible then you need a conditional section around each table and some field you can use for that conditional merge section. Create rollup fields on the Opportunity to provide a count for each product category.  Then create a formula/checkbox field to be TRUE if the rollup field is greater than 0.  And use that field as the condition for the conditional section.