Forum Discussion

EzadineAlwajeeh's avatar
EzadineAlwajeeh
New Member
1 year ago

Promotions

Hello, I have a Promotions table with the following columns: City Name, Product Type, Promotion Start Date, Promotion End Date, and Promotion Value. I also have a Sales table with the following columns: City Name, Product Type, Goods Entry Date to the factory with date and time, Goods Exit Date from the factory with date and time, Good Value, Customer Name, and Customer ID. My question is that I want to calculate the promotion value for each Good, with several conditions. Each city and product type has its own specific promotions, and if the current promotion is greater than the previous promotion, the start date of the current promotion begins from the goods exit date at 12 PM. If the current promotion is smaller than the previous promotion, the start date of the goods begins from the goods entry date at 7 AM. I need a DAX formula to add a column to calculate the promotion value for each Good in the Sales table. Thank you.

3 Replies