Need help in shortening formula.

BigMoe

New Member
Joined
Nov 1, 2014
Messages
18
*** I'm using Excel 2003 ***

This is more of a general question because I don't have the whole formula 100% figured-out, but I would appreciate some direction on how to either make the formula below shorter (I've run into the Excel limit) or go about it in a more efficient way (without VBA please). I'm a bit of a self-taught Excel weekend warrior, so I'm open to using a completely different formula if need-be.

=IF(SHEETOFFSET(-1,$D$169)<sheetoffset(-1,$h$173),vlookup(sheetoffset(-1,$h$164),tables!$d$1:$e$16,2,0), if(and(vlookup(sheetoffset(-1,$h$164),tables!$m$21:$n$36,2,0)<4,sheetoffset(-1,$d$170)="">0,SHEETOFFSET(-1,$H$175)>=1, SHEETOFFSET(-1,$D$168)>=SHEETOFFSET(-1,$H$168)),VLOOKUP(SHEETOFFSET(-1,$H$164),Tables!$A$1:$B$16,2,0), IF(AND(VLOOKUP(SHEETOFFSET(-1,$H$164),Tables!$M$21:$N$36,2,0)=4,SHEETOFFSET(-1,$H$165)="A",SHEETOFFSET(-1,$D$165)>0, SHEETOFFSET(-1,$H$175)>=1,SHEETOFFSET(-1,$D$168)>=SHEETOFFSET(-1,$H$168),SHEETOFFSET(-1,$D$170)>0), VLOOKUP(SHEETOFFSET(-1,$H$164),Tables!$A$1:$B$16,2,0),IF(AND(OR(VLOOKUP(SHEETOFFSET(-1,$H$164),Tables!$M$21:$N$36,2,0)=5, VLOOKUP(SHEETOFFSET(-1,$H$164),Tables!$M$21:$N$36,2,0)=6,VLOOKUP(SHEETOFFSET(-1,$H$164),Tables!$M$21:$N$36,2,0)=7), SHEETOFFSET(-1,$H$165)="A",SHEETOFFSET(-1,$D$165)>0,SHEETOFFSET(-1,$D$168)>=SHEETOFFSET(-1,$H$168),SHEETOFFSET(-1,$D$170)>0), VLOOKUP(SHEETOFFSET(-1,$H$164),Tables!$P$21:$Q$36,2,0),SHEETOFFSET(-1,$H$164)))))

I've read-up on "Named Formulas", but having some trouble putting it in practice. For example, I tried naming the following parts of the formula, but end up getting errors:
Trial #1 (SHEETOFFSET(-1,$D$169)...<sheetoffset(-1,$h$173),vlookup(sheetoffset(-1,$h$164),tables!$d$1:$e$16,2,0)<sheetoffset(-1,$h$173),vlookup(sheetoffset(-1,$h$164),tables!$d$1:$e$16,2,0)<sheetoffset(-1,$h$173),vlookup(sheetoffset(-1,$h$164),tables!$d$1:$e$16,2,0)

Trial #2 SHEETOFFSET(-1,$D$169)...<sheetoffset(-1,$h$173),vlookup(sheetoffset(-1,$h$164),tables!$d$1:$e$16,2,0)<sheetoffset(-1,$h$173),vlookup(sheetoffset(-1,$h$164),tables!$d$1:$e$16,2,0)<sheetoffset(-1,$h$173),vlookup(sheetoffset(-1,$h$164),tables!$d$1:$e$16,2,0)

Trial #3 IF(SHEETOFFSET(-1,$D$169)...<sheetoffset(-1,$h$173),vlookup(sheetoffset(-1,$h$164),tables!$d$1:$e$16,2,0)<sheetoffset(-1,$h$173),vlookup(sheetoffset(-1,$h$164),tables!$d$1:$e$16,2,0)<sheetoffset(-1,$h$173),vlookup(sheetoffset(-1,$h$164),tables!$d$1:$e$16,2,0)

Any tips, advice, or examples using the formula above would be of great help, thanks. </sheetoffset(-1,$h$173),vlookup(sheetoffset(-1,$h$164),tables!$d$1:$e$16,2,0)<sheetoffset(-1,$h$173),vlookup(sheetoffset(-1,$h$164),tables!$d$1:$e$16,2,0)<sheetoffset(-1,$h$173),vlookup(sheetoffset(-1,$h$164),tables!$d$1:$e$16,2,0)
</sheetoffset(-1,$h$173),vlookup(sheetoffset(-1,$h$164),tables!$d$1:$e$16,2,0)<sheetoffset(-1,$h$173),vlookup(sheetoffset(-1,$h$164),tables!$d$1:$e$16,2,0)<sheetoffset(-1,$h$173),vlookup(sheetoffset(-1,$h$164),tables!$d$1:$e$16,2,0)
</sheetoffset(-1,$h$173),vlookup(sheetoffset(-1,$h$164),tables!$d$1:$e$16,2,0)<sheetoffset(-1,$h$173),vlookup(sheetoffset(-1,$h$164),tables!$d$1:$e$16,2,0)<sheetoffset(-1,$h$173),vlookup(sheetoffset(-1,$h$164),tables!$d$1:$e$16,2,0)
</sheetoffset(-1,$h$173),vlookup(sheetoffset(-1,$h$164),tables!$d$1:$e$16,2,0),>
 
Last edited:

Excel Facts

When did Power Query debut in Excel?
Although it was an add-in in Excel 2010 & Excel 2013, Power Query became a part of Excel in 2016, in Data, Get & Transform Data.
This formula compares the current level of a student and goes through a set of complex variables to see if they will be promoted or demoted to another level.

I realize that the help I'm going to receive is on the general side, but that's fine. I just don't know how else to word long formulas like this since I'm not an advanced user. I'm reading-up on Named Formulas at the moment, but not having much success. Is there a way of using helper columns or additional tables to simplify things? Any pointing in a possible direction would be helpful.
 
Upvote 0
What are the criteria for promotion or demotion? For instance, Student Timmy should be promoted if column B is greater than 2 and column C is equal to Red, but not if Column D is equal to "F", etc.

What value should the formula return? Promote, Demote, No Action?

It may be complicated to describe, but it's even more complicated to solve without a description I'm afraid...
 
Upvote 0

Forum statistics

Threads
1,214,922
Messages
6,122,281
Members
449,075
Latest member
staticfluids

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