Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Find everything you need to get certified on Fabric—skills challenges, live sessions, exam prep, role guidance, and more. Get started

Reply
Anonymous
Not applicable

Double revenue showing up in Card

Hi All,

 

I have a situation in my report where a single deal is having 2 stakeholders but when I'm calculating total revenue it is adding both the rows whereas it should add only distinct deal.

 

Like in the below screenshot I want to show the sum as $341.10 but it is doublng since I have 2 stakeholders on the same deal.

How can this be resolved?

 

I want to calculated Revenue with distinct Deal ID like below

 

Gross Revenue = CALCULATE(DISTINCTCOUNT(View_DealClosing[ID]) && CALCULATE(SUM(View_DealClosing[Estrevenue])))

 

 

Himanshu_13_0-1634122040063.png

 

For reference ( This is showing up wrong as its doubling the revenue) :

 

Himanshu_13_0-1634123404163.png

 

Kindly help in resolving this.

 

Regards,

Himanshu

1 ACCEPTED SOLUTION

Hi,  @Anonymous 

Since this result is being calculated multiple times, you can try to divide the result by each count of id (2).

C_Gross Revenue = 
VAR count_eachID =
    CALCULATE (
        COUNTROWS ( View_DealClosing ),
        ALLEXCEPT ( View_DealClosing, View_DealClosing[ID] )
    )
RETURN
    View_DealClosing[Estrevenue] / count_eachID

97.png

Youcan also try measure to change total value in table visual as below:

Gross Revenue =
IF (
    HASONEVALUE ( View_DealClosing[ID] ),
    SUM ( View_DealClosing[Estrevenue] ),
    SUM ( View_DealClosing[Estrevenue] ) / 2
)

 

Best Regards,
Community Support Team _ Eason

View solution in original post

4 REPLIES 4
Anonymous
Not applicable

@amitchandak can you help here?

 

Regards,

Himanshu

@Anonymous , Try like

Gross Revenue = sumx(values(View_DealClosing[ID]), CALCULATE(SUM(View_DealClosing[Estrevenue])))

 

but what is the benefit if both are sum

 

may be

 

Gross Revenue = sumx(values(View_DealClosing[ID]), CALCULATE(max(View_DealClosing[Estrevenue])))

Anonymous
Not applicable

Its giving me an error when I'm trying to create a 2nd calculated column using the above calculation.

 

Himanshu_13_0-1634131689149.png

 

Hi,  @Anonymous 

Since this result is being calculated multiple times, you can try to divide the result by each count of id (2).

C_Gross Revenue = 
VAR count_eachID =
    CALCULATE (
        COUNTROWS ( View_DealClosing ),
        ALLEXCEPT ( View_DealClosing, View_DealClosing[ID] )
    )
RETURN
    View_DealClosing[Estrevenue] / count_eachID

97.png

Youcan also try measure to change total value in table visual as below:

Gross Revenue =
IF (
    HASONEVALUE ( View_DealClosing[ID] ),
    SUM ( View_DealClosing[Estrevenue] ),
    SUM ( View_DealClosing[Estrevenue] ) / 2
)

 

Best Regards,
Community Support Team _ Eason

Helpful resources

Announcements
Europe Fabric Conference

Europe’s largest Microsoft Fabric Community Conference

Join the community in Stockholm for expert Microsoft Fabric learning including a very exciting keynote from Arun Ulag, Corporate Vice President, Azure Data.

Power BI Carousel June 2024

Power BI Monthly Update - June 2024

Check out the June 2024 Power BI update to learn about new features.

RTI Forums Carousel3

New forum boards available in Real-Time Intelligence.

Ask questions in Eventhouse and KQL, Eventstream, and Reflex.