Skip to main content

I have a dataset that contains leads that were converted into an opportunity, as well as the opportunity details. I want to use the same dataset for both counting the number of unique leads, but also the total amount of opportunities. Unfortunately, in some cases more than one lead gets converted into the same opportunity, causing duplicate opportunity amounts. How do you Amount sum only once per unique opportunityID

1 answer
  1. May 2, 2024, 9:58 PM

    My current solution is to use the row number window function and then sum only those that have a row number of 1. Is there a better way?

0/9000