locked
Calculated Column - Identify the value of selected End Date RRS feed

  • Question

  • Hi Experts,

    I need help in creating calculated column.

    I have a report where user is able to pick Start and End Date. My requirement is, how can I show the value of SOLD of the selected end date in my new column? I saw LastDate function in the list. How can I use this in my calculated column? 

    Thanks


    • Edited by glenn_26 Thursday, January 21, 2016 7:37 AM
    Thursday, January 21, 2016 7:36 AM

Answers

  • Hi,

    using start date and end date is not a good idea. It is better to use one date filter and check multiple days in that filter.

    Expression would look like this.

    End Date Sales :=
    CALCULATE (
        SUM ( Sales[TotalPrice] );
        FILTER ( Calendar; Calendar[EndDate] = MAX ( Calendar[EndDate] ) )
    )
    • Marked as answer by glenn_26 Thursday, January 21, 2016 10:45 AM
    Thursday, January 21, 2016 9:50 AM

All replies

  • Hi,

    using start date and end date is not a good idea. It is better to use one date filter and check multiple days in that filter.

    Expression would look like this.

    End Date Sales :=
    CALCULATE (
        SUM ( Sales[TotalPrice] );
        FILTER ( Calendar; Calendar[EndDate] = MAX ( Calendar[EndDate] ) )
    )
    • Marked as answer by glenn_26 Thursday, January 21, 2016 10:45 AM
    Thursday, January 21, 2016 9:50 AM
  • Ok, will try this one. Thanks for the reply!
    Thursday, January 21, 2016 10:45 AM