Don't miss your chance to take the Fabric Data Engineer (DP-700) exam on us!
Learn moreWe've captured the moments from FabCon & SQLCon that everyone is talking about, and we are bringing them to the community, live and on-demand. Starts on April 14th. Register now
I am looking to indentify customers who were present in a month and also present in the same month previous year.
Example below
Should be present column just to illustrate. That eg. client 3001 was not present in Aug-22 as no purchase value but client 101001, 115001 are present in both Aug-22 and Aug-23.
| cl Code | Aug-22 | Aug-23 | Should be present |
| 3001 | 0 | 44.32 | n |
| 101001 | 42.94 | 90.68 | y |
| 115001 | 298 | 685 | y |
| 121921 | 18.24 | 0 | n |
| 123818 | 30.5 | 28 | y |
| 123819 | 1204.66 | 94.9 | y |
| 202004 | 67.1 | 0 | n |
| 202008 | 277.28 | 282.14 | y |
| 247008 | 16.8 | 0 | n |
| 247009 | 6.1 | 0 | n |
| 247012 | 214.6 | 196.75 | y |
| 288001 | 786.54 | 633.95 | y |
| 360008 | 160.24 | 0 | n |
| 360009 | 81.44 | 0 | n |
Solved! Go to Solution.
@fazza1991 , Assume you have measure sales and you are using date table
then
Year behind Sales = CALCULATE([Sales],dateadd('Date'[Date],-1,Year))
Year behind Sales = CALCULATE([Sales],SAMEPERIODLASTYEAR('Date'[Date]))
Countx(values(Customer[Customer]) ,
If(not(isblank([Sales])) && not(isblank([Year behind Sales])) , [Customer], blank())
same a customer Retention
Hi, @fazza1991
What does your source data look like? Is it possible to give an example? Is the date a column name or a column value?
Best Regards,
Community Support Team _Charlotte
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
@fazza1991 , Assume you have measure sales and you are using date table
then
Year behind Sales = CALCULATE([Sales],dateadd('Date'[Date],-1,Year))
Year behind Sales = CALCULATE([Sales],SAMEPERIODLASTYEAR('Date'[Date]))
Countx(values(Customer[Customer]) ,
If(not(isblank([Sales])) && not(isblank([Year behind Sales])) , [Customer], blank())
same a customer Retention
If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.
A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.
Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.
| User | Count |
|---|---|
| 51 | |
| 37 | |
| 35 | |
| 19 | |
| 17 |
| User | Count |
|---|---|
| 70 | |
| 64 | |
| 39 | |
| 33 | |
| 23 |