0

Our organization runs a daily transaction list (via saved search) to forecast our opportunity pipeline. For this saved search, we set the customer mainline to false to eliminate duplicate values in our search.

I've built a saved search text formula that references the customer sales team, which I understand is a sublist. This sublist doesn't play nicely with my transaction report and results in duplicate values.

What I want to have happen is for the transaction line item to pull in the name of the sales team member who has a sales team role of "team lead". If there isn't a sales team member with the team lead role, then I want the result to be blank. We do not have any sales teams where there are two team leads, so we will never run up against this.

The problem I'm getting is duplicate values. The report interprets my code to mean if a customer has a sales team member with the team lead role, then duplicate that line item as many times are there are sales team members. As an example, I have a customer with 8 sales team members. My code results in 8 duplicate line items and one line item has the name of the team lead while the rest are blank.

Thoughts on how to resolve? Thank you in advance. My code looks like this:

I cannot change customer main line to false, as this is makes it even more complicated. Leaving customer main line as false displays exactly what I need currently, with exception of the name of the team lead.

CASE WHEN {customer.salesteamrole} = 'Team Lead' THEN {customer.salesteammember} ELSE NULL END

What I'm looking for is one line item for each transaction and simply the name of the team lead on that transaction. Perhaps the answer is to create a custom field, but I'd like to think the solution can be accomodated in a transaction report.

1 Answers1

0

You can set a filter in the Criteria tab to make sure only the lines that you want are returned. In the Criteria tab under Filter, select the Formula (Numeric) option, and set the Formula to be:

CASE WHEN {customer.salesteamrole} = 'Team Lead' THEN 1 ELSE 0 END

then choose 'equal to' in the operator field and put 1 for the value.

Krypton
  • 4,394
  • 2
  • 9
  • 13