Comparing 3 data sets

awhiterussian

New Member
Joined
Jul 27, 2007
Messages
10
The concept behind it is this: The promotion calendar looks like this:

Account Product Start Date End Date

Kroger Milk 01/2/2007 01/25/2007
Walmart yogurt 02/25/2007 03/05/2007
Albertsons milk 03/15/2007 03/20/2007

Now each specific deal refers to a specific customer and product. So, i'm matching this to the shipment data that looks like this:

Account Product Cases Shipped Date

Kroger milk 400 03/25/2007
Walmart yogurt 350 04/15/2007


So what i'm trying to do is from the shipment data to look up and see if that specific product was delivered to the customer was on promotion. So i'm looking up the product and the customer, taking that shipment date and see if it falls in an interval of dates in the promotion calendar. And if the shipment date falls in that interval, then it should return an asterisk.

=IF(ISNA(MATCH(A2,$H$2:$H$476)*AND((B2>=MIN(I2)),B2<=MAX(J2))),0,"*")

where A2 is the concatenation of product and account
H2:H476 is where all my customer/product concatenations are
B2 is the shipment date
I2 is start of promotion
J2 is end of promotion

Hope thats specific enough.

Thanks! Just learning this whole logic of excel business and I appreciate your help.

Seva
 

Excel Facts

How to fill five years of quarters?
Type 1Q-2023 in a cell. Grab the fill handle and drag down or right. After 4Q-2023, Excel will jump to 1Q-2024. Dash can be any character.

Forum statistics

Threads
1,181,055
Messages
5,927,861
Members
436,573
Latest member
CMR237

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Top