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

Join the FabCon + SQLCon recap series. Up next: Power BI, Real-Time Intelligence, IQ and AI, and Data Factory take center stage. All sessions are available on-demand after the live show. Register now

Reply
sprao
Helper I
Helper I

Total Sum

Hi All,

 

Sorry everyone...May be for you all its basic question, but i just stareted learning i need your help..

 

How to sumup sales for last selection in filter,(Ex:ABC21)

q5.PNG

 

 

 

 

 

 

 

 

here i want show when i select Year:ABC21 need my result in graph 175.Thank you all

 

Q4.PNG

 

 

 

 

 

 

 

 

 

 

 

 

Thank you all

 

1 ACCEPTED SOLUTION
Anonymous
Not applicable

Hi @sprao ,

Use below steps to achieve this,

Measure:

SUM_Sales = IF(SELECTEDVALUE('Table'[Year])="ABC1",CALCULATE(SUM('Sample'[Sales]),ALL('Sample'[Year])),CALCULATE(SUM('Sample'[Sales]),USERELATIONSHIP('Sample'[Year],'Table'[Year])))


Inactive Relation:

 

Relation.PNG

 

ABC1:

ABC.PNG

For 2020:

2020.PNG


Best Regards,

Mail2inba4

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

4 REPLIES 4
Anonymous
Not applicable

Hi @sprao ,

Use below steps to achieve this,

Measure:

SUM_Sales = IF(SELECTEDVALUE('Table'[Year])="ABC1",CALCULATE(SUM('Sample'[Sales]),ALL('Sample'[Year])),CALCULATE(SUM('Sample'[Sales]),USERELATIONSHIP('Sample'[Year],'Table'[Year])))


Inactive Relation:

 

Relation.PNG

 

ABC1:

ABC.PNG

For 2020:

2020.PNG


Best Regards,

Mail2inba4

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

its not working for me..i given below DAX formula..Q6.PNG

 

 

Really sorry my above reply your solution worked.. i forgot to inactive relation between tables in above post...

Anonymous
Not applicable

@sprao  - There are several options here, each with drawbacks:

  1. UNION a row into the table for the total - this will be problematic, because the Total will be doubled when unfiltered.
  2. Simply consider the lack of a filter (Grand Total) to be the value you're looking for. However, if the category only covers a certain subset of years, this won't work properly.
  3. If #2 doesn't work, try creating a separate column for the Year Category. Then use the new column as a filter instead of the years.
I hope this helps. If it does, please Mark as a solution.
I also appreciate Kudos.

Helpful resources

Announcements
April Power BI Update Carousel

Power BI Monthly Update - April 2026

Check out the April 2026 Power BI update to learn about new features.

New to Fabric survey Carousel

New to Fabric Survey

If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.

FabCon and SQLCon Highlights Carousel

FabCon &SQLCon Highlights

Experience the highlights from FabCon & SQLCon, available live and on-demand starting April 14th.