Vlookup
Posted by Ian Mac on October 29, 2001 5:06 AM
Hello All,
I can't seem to get my head round this today!
What I need to do is use vlookup to look at a persons name then if there start date is <=14 (days) return 3, (>14 and <=35) return 5, >35 return 6.
I've done this using nested if (ugly and long winded), I'd like to do the same thing using some kinda of lookup in the original lookup, so it can return a lot more values. the reason is that the above numbers are for only 1 shift length and there are three.
I started with IF(NOW()-VLOOKUP(B5,'Master Data Sheet'!C2:V135,14,0)<=14,3,IF(.... but this is gonna get too big.
I've seen it before (and used it i think) where you can place the array in the lookup for the second part,
something like, but not:
{"<=14",3;"<=35",5;">35",6}
Are can't figure out how to get Excel to see the <=14 part as the test part of the formula.
as I've explained I the have to use if the lookup returns 6hrs then a whole different set of values.
Any help would be muchly nice
Thanks
Ian Mac