offset, match index?

Wiryeman

New Member
Joined
Jun 25, 2008
Messages
5
I have a output from an accounting product and I need to reformat the table.

At the bottom starting at row 23 you can see an example of the new worksheet I am trying to create.

Can I get help with a formula to help automate this? The original report has 742 more accounts like this I need to reformat.


Offsetlookup.xlsx
ABCD
1Program export
2JulyAugustSeptember
3Income
4General Income
5Collections, Adult
64110Collections, Adult
7Current Year Budget000
8Current Year Actual34,759.1642,175.2732,636.98
9Last Year Actual38,041.9138,816.3954,266.71
10Current Year Actual/Budget34,759.1642,175.2732,636.98
11Offertory Collections, Youth
124111Collections, Youth
13Current Year Budget000
14Current Year Actual51015
15Last Year Actual000
16Current Year Actual/Budget000
17
18
19
20
21
22
23Output worksheet
24JulyAugustSpet
25411034,759.1642,175.2732,636.98
26411151015
Sheet1


Thank you in advance
Jeff
 

Excel Facts

Back into an answer in Excel
Use Data, What-If Analysis, Goal Seek to find the correct input cell value to reach a desired result
Hey Jeff - what might help is better understanding how ALL of the data is formatted. You mentioned there are 742 accounts - do they all show up in the same report - so would they all be one after another, on the same spreadsheet tab? Are there any variations in the format of each section, or are the row and column layouts the same for each account?
 
Upvote 0
Hey Jeff - what might help is better understanding how ALL of the data is formatted. You mentioned there are 742 accounts - do they all show up in the same report - so would they all be one after another, on the same spreadsheet tab? Are there any variations in the format of each section, or are the row and column layouts the same for each account?
Hi Gimics,

The top portion of the example is the format for all accounts. It continues repeating blocks, if you will, for each account and it extends over 12 months to the right.

Does that help?
 
Upvote 0
It does!

Have you ever used the combination =index(match()) formulas? this would be a great opportunity to use those - Index allows you to return the value from a table by providing the formula with a column number and a row number, while match lets you find the column and row number.

The nice thing is that you can just tweak the numbers that are returned by the match() formula to "offset" for your layout.

For example, if you used the match formula to lookup the ROW that your first account 4110 is in
Excel Formula:
=MATCH($A25,$A$1:$A$22)
it would return the value "6" because it exists in ROW 6. However, if you wanted to offset this, you could just add +2 to the end of the formula to return the values in the Current Year Actual row.

So your index formula could look something like this:

Excel Formula:
=INDEX($A$1:$M$22,MATCH($A25,$A$1:$A$22,0)+2,MATCH($B24,$B$2:$M$2,0))

And that should be useable across the whole chart in your screenshot. You would have to tweak the range sizes for your larger report.You can adjust the +2 to whatever you need for the correct row of data you're looking for.
 
Upvote 0
Solution

Forum statistics

Threads
1,215,102
Messages
6,123,097
Members
449,096
Latest member
provoking

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