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

Find everything you need to get certified on Fabric—skills challenges, live sessions, exam prep, role guidance, and more. Get started

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
Europe Fabric Conference

Europe’s largest Microsoft Fabric Community Conference

Join the community in Stockholm for expert Microsoft Fabric learning including a very exciting keynote from Arun Ulag, Corporate Vice President, Azure Data.

Power BI Carousel June 2024

Power BI Monthly Update - June 2024

Check out the June 2024 Power BI update to learn about new features.

PBI_Carousel_NL_June

Fabric Community Update - June 2024

Get the latest Fabric updates from Build 2024, key Skills Challenge voucher deadlines, top blogs, forum posts, and product ideas.

Top Solution Authors