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

The Power BI DataViz World Championships are on! With four chances to enter, you could win a spot in the LIVE Grand Finale in Las Vegas. Show off your skills.

Reply
tomhopewell
Frequent Visitor

Retained Deposits DAX

Hi all,

 

I am trying to calculated all of our "Retained First Time Deposits" which are basically all customers who made their first deposit in month 0 and then went on to make another deposit in month 1.

 

I currently have this...

 

Retained FTDs = COUNTROWS (
FILTER (
ADDCOLUMNS (
VALUES ( 'Fact Transactions'[PlayerKey] ),
"LastMonthTotal", CALCULATE (
COUNTROWS ('Fact Transactions'),
FILTER (
ALL ('Dim Date'),
'Dim Date'[MonthIndex]=MIN('Dim Date'[MonthIndex])-1
)
),
"PreviousMonthTotal", CALCULATE (
COUNTROWS ('Fact Transactions'),
FILTER (
ALL ('Dim Date'),
'Dim Date'[MonthIndex]=MIN('Dim Date'[MonthIndex])-2),'Fact Transactions'[isInitialDeposit] = TRUE)
),NOT(ISBLANK([LastMonthTotal])) && NOT(ISBLANK([PreviousMonthTotal]))))
 
Note:
MonthIndex  = Running number for each month
 
Currently, the numbers it is returning are lower than they should be and i'm unsure as to where it's going wrong. Unfortunately, due to the sensitive nature of the data, I can't provide any samples.
 

I am new to DAX so any help would be greatly appreciated.

 

Thanks in advance,

Tom

1 ACCEPTED SOLUTION
v-chuncz-msft
Community Support
Community Support

@tomhopewell ,

 

You may try using INTERSECT.

https://community.powerbi.com/t5/Desktop/Want-to-calculate-number-of-new-customers-per-every-month-o...

Community Support Team _ Sam Zha
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

1 REPLY 1
v-chuncz-msft
Community Support
Community Support

@tomhopewell ,

 

You may try using INTERSECT.

https://community.powerbi.com/t5/Desktop/Want-to-calculate-number-of-new-customers-per-every-month-o...

Community Support Team _ Sam Zha
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!

FebPBI_Carousel

Power BI Monthly Update - February 2025

Check out the February 2025 Power BI update to learn about new features.

Feb2025 NL Carousel

Fabric Community Update - February 2025

Find out what's new and trending in the Fabric community.