Latest Enterprise DNA Initiatives


Calculate revenue

I have two tables Dates and sales and I’m using a Date Slicer

I will like to calculate revenue from the sales table using a static date AND ignore the date slice

Static date is Year 2021

How can I use the calculate function

CALCULATE(
SUMX( Sales ,
Sales[revenue] ) ,
FILTER

Why use Calculate? I don’t think you need it

Total Revenue = Sum(Sales(revenue)) in a measure not calculated column

I guess you didn’t read the whole question. What about the slicer and the static year. ? I need to calculate all record for that year without using the slicer. I am using the slicer for other items on the page.

have you checked the learning portal?

I hope you did

always do the research before i post a question :slight_smile:

1 Like
Sales in Range =
CALCULATE(
    SUM( Sales[Revenue] ),
    FILTER(
        Dates,
        [Date] >= DATE(2020,01,01) &&
        Dates[Date] <= DATE(2020,12,31)
    )
)

Tweak the filter as needed.

Select the slicer, go to Format → Edit Interactions. Your visualisations will have icons at the top right now. Select “None” for the visualisation you have put this measure in, the slicer will not effect it.