Advance your Data & AI career with 50 days of live learning, dataviz contests, hands-on challenges, study groups & certifications and more!
Get registeredGet Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Learn more
I have two tables with one to many relationship:
Table1: Sales:
| Sales Id | Customer Id |
| 9001 | A |
| 9002 | B |
| 9003 | B |
| 9004 | A |
| 9005 | D |
| 9006 | E |
Table2: Sales details:
| Sales Id | Campaign Id |
| 9001 | C1 |
| 9001 | C8 |
| 9002 | C3 |
| 9002 | C10 |
| 9002 | C11 |
| 9003 | C40 |
| 9004 | C1 |
| 9004 | C18 |
| 9005 | C3 |
| 9006 | C6 |
| 9006 | C6 |
| 9006 | C10 |
You should know that the column "Customer_Id" has blanks.
I want to calculate how many purchases a customer did by campaign. Any thoughts?
Thanks on advanced
Solved! Go to Solution.
Hello: Here is the avg campaings/known customer. I hope this is what you are looking for.
https://drive.google.com/file/d/1VtPEjBK70Msz5hQcBtKZU4X9bl-eSQcT/view?usp=sharing
Hello: Here is the avg campaings/known customer. I hope this is what you are looking for.
https://drive.google.com/file/d/1VtPEjBK70Msz5hQcBtKZU4X9bl-eSQcT/view?usp=sharing
Thank you for your reply.
This is exactly what I'm after but I face a problem. The column "Customer ID" has blanks. I tried to replace "VALUES" with "DISTINCT" and "ALLNOBLANKROW" but it didn't solve it. Do you have any suggestion about this?
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!
Check out the October 2025 Power BI update to learn about new features.
| User | Count |
|---|---|
| 8 | |
| 5 | |
| 4 | |
| 3 | |
| 3 |
| User | Count |
|---|---|
| 24 | |
| 12 | |
| 11 | |
| 9 | |
| 8 |