Pull data from a table to matching Vertical and Horizontal Criteria

sanantonio

Board Regular
Joined
Oct 26, 2021
Messages
124
Office Version
  1. 365
Platform
  1. Windows
Hi All,

Normally I would be able to manipulate the data prior to extraction to make it "pivotable" but alas we have one KPI measured by an antiquated system that does not allow for editing prior to export so I get that looks like this:

1683644508601.png


What I need to be able to do is have a formula that will return a value between D2 to Q9999 when it matches 3 criteria: Item Nr, DC (The Verticals) and Week number (The Horizontal).

1683644623939.png


I've tried some Index/Match's but can't get it to work with the mixture of vertical and horizontal.

Open to any solution, even if someone had a loop macro that would convert the data into a pivotable format...
(This is an example I put together manually, but this manual creation isn't feasible because I have 600+ items)
1683644724538.png


Thanks in advance!
 

Excel Facts

Copy formula down without changing references
If you have =SUM(F2:F49) in F50; type Alt+' in F51 to copy =SUM(F2:F49) to F51, leaving the formula in edit mode. Change SUM to COUNT.
How about
Excel Formula:
=SUMPRODUCT((B2:B1000=X9)*(C2:C1000=Y9)*(D1:Q1=Z9)*(D2:Q1000))
 
Upvote 1
Solution
You sir! Have saved my ****.

Thank you for the quick response!
 
Upvote 0
Load your data to Power Query (Get and Transform Data on the Data Tab). In the PQ editor, click on Transform. Highlight columns B and C. Select Unpivot and Unpivot other columns. On the home tab close and load to a table. Select location.
 
Upvote 0
You're welcome & thanks for the feedback.
 
Upvote 0

Forum statistics

Threads
1,214,834
Messages
6,121,873
Members
449,056
Latest member
ruhulaminappu

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
Back
Top