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

Calling all Data Engineers! Fabric Data Engineer (Exam DP-700) live sessions are back! Starting October 16th. Sign up.

Reply
AwaisAnwar
Frequent Visitor

Getting Prior week sales in summarize table

Hi, I need help. I am trying to find mark weekly status of customer if he is new customer, lost customer or restart customer. i am unable to find previous week sales before week in context to decide its a new customer or restart

 

AwaisAnwar_0-1705367087577.png

 

1 ACCEPTED SOLUTION
LufengYuan
Frequent Visitor

Here is a similar data with yours. 

1. add a WeekNum column WeekNum = WEEKNUM('Table1'[dateExam])

2. then calculate previous week total number that is total sales in your case.

3. then use IF statement to flag the customers

 

Hope this is helpful for you.

 

LufengYuan_0-1705370545285.png

 

View solution in original post

2 REPLIES 2
LufengYuan
Frequent Visitor

Here is a similar data with yours. 

1. add a WeekNum column WeekNum = WEEKNUM('Table1'[dateExam])

2. then calculate previous week total number that is total sales in your case.

3. then use IF statement to flag the customers

 

Hope this is helpful for you.

 

LufengYuan_0-1705370545285.png

 

Thanks

Helpful resources

Announcements
November Fabric Update Carousel

Fabric Monthly Update - November 2025

Check out the November 2025 Fabric update to learn about new features.

Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.

Users online (25)