Forum Discussion
Line chart with selected customers only
I have a line chart which show the sales of customers (over 1K). I have multiple slicers such as year, month, region etc, and one of slicer is customers which I can select a few customers (e.g. customer A, B and C). The line chart and slicers works very well. Now I need to show the sales of all customers at the same char, along with selected customers (e.g. customer A, B and C). How can I do that? Thanks
Hi,
See if my solution in the attached file helps.
Yes. To answer your question "where is the "total sales all customer" created?" that's up for you know, what goes there is the column or sum measure you are using to represent the numerical values. You won't need to include any selected customers in the formula, by using your filters and slicers, your measure will consider those as part of the row context.
6 Replies
- Ashish_MathurSuper User
- AnonymousNot applicable
Thank you Ashish_Mathur . Wonderful demo
- Ashish_MathurSuper User
Thank you.
- ray_aramburoSuper User
You can use a formula like this:
Total Sales All Customers = CALCULATE( SUM(SalesTable[SalesValuesColumn]), ALLEXCEPT('Customers Table', 'Customers Table'[Customer)))Just keep in mind that if your chart has additional layers of segmentations, you'll need to add those fields in the ALLEXCEPT function (for example, the year column, the month, etc.)
- AnonymousNot applicable
Thank you ray_aramburo. Are you talking about create a new measure ? where is the "total sales all customer" created? those selected customers are dynamic, could be customer A, B,C or X, Y, Z depending on the user. So I am a little bit lost here how can I put the customers selected by slicers in the formula.
- ray_aramburoSuper User
Yes. To answer your question "where is the "total sales all customer" created?" that's up for you know, what goes there is the column or sum measure you are using to represent the numerical values. You won't need to include any selected customers in the formula, by using your filters and slicers, your measure will consider those as part of the row context.