Forum Discussion

snandy2011's avatar
snandy2011
Helper IV
7 years ago
Solved

How to count user within specific time frame

Hi all,   I am going to work on a situation where i do need a help. Below is the scenario,   Suppose i have some user deposited data (user who have deposited amount). Lets say,   User    Amount...
  • v-jiascu-msft's avatar
    v-jiascu-msft
    7 years ago

    Hi snandy2011,

     

    Please download the solution from the attachment.

    1. Create a column.

    Column =
    VAR firstDeposit =
        CALCULATE ( MIN ( 'Table1'[Date] ), ALLEXCEPT ( Table1, Table1[User] ) )
    VAR records30Days =
        CALCULATE (
            COUNTROWS ( 'Table1' ),
            FILTER (
                ALLEXCEPT ( Table1, Table1[User] ),
                'Table1'[Date] >= firstDeposit
                    && 'Table1'[Date] <= EDATE ( firstDeposit, 1 )
            )
        )
    RETURN
        IF ( records30Days > 1, "FTD", "Other" )
    

    2. Create four measures.

    How-to-count-user-within-specific-time-frame-u

     

    Best Regards,
    Dale