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

Vote for your favorite vizzies from the Power BI Dataviz World Championship submissions. Vote now!

Reply
davepdc
New Member

Help combining spend and sales tables

I have source two tables I'd like to combine into a third table. The first table tracks campaign spend for two products by day. The second table has resulting sales of those products, also by day. Sales may occur on days where no spend occured (we have an ad running day 1, but response isn't until day 2 for example).

 

What is the best way to generate table C? I've come up with ways to merge on a key based on date-campaign-sku, but then I end up missing sales on days with no spend (or spend on days with no sales). What would be the correct way to create the new table in Power BI?

 

Thank you!

merge-sample.jpg

1 REPLY 1
amitchandak
Super User
Super User

@davepdc , One option is to have a full Outer join. But I would advise Append and aggregate.

As one column name is diff. The append will add that as a new column. Now go do aggregate in Power query or you can leave that to visualization

 

https://radacad.com/append-vs-merge-in-power-bi-and-power-query

https://radacad.com/power-bi-aggregation-step-1-create-the-aggregated-table

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

Vote for your favorite vizzies from the Power BI World Championship submissions!

Sticker Challenge 2026 Carousel

Join our Community Sticker Challenge 2026

If you love stickers, then you will definitely want to check out our Community Sticker Challenge!

January Power BI Update Carousel

Power BI Monthly Update - January 2026

Check out the January 2026 Power BI update to learn about new features.

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.