# Quick help with IF Statement

#### golfnut019

##### Board Regular
=IF(ISBLANK(P6574),VLOOKUP(G6574,'HC-CID'!A\$2:I\$65185,8,FALSE),IF(Q6574>37809,VLOOKUP(G6574,'HC-LID2'!A\$2:I\$65185,8,FALSE),VLOOKUP(G6574,'HC-LID'!A\$2:I\$65185,8,FALSE)))

Here's what's going on :

the isblank part is pretty self-explanatory.

I want the formula to check the data, and if it's greater than 12/23/2005, it'll look for the G value in the HC-LID2 sheet and if it's less than or equal 12/23/2005, it'll go to the HC-LID sheet.

I keep getting a #N/A for dates less than or equal to 12/23/2005 although when i manually look up the G value in the HC-LID sheet it's there.

Is there anything fundamentally wrong with the formula?

Thanks

### Excel Facts

Enter current date or time
Ctrl+: enters current time. Ctrl+; enters current date. Use Ctrl+: Ctrl+; Enter for current date & time.

#### golfnut019

##### Board Regular
To make it easier, if the value in column P is not blank, I run IF(Q6574>37809,VLOOKUP(G6574,'HC-LID2'!A\$2:I\$65185,8,FALSE),VLOOKUP(G6574,'HC-LID'!A\$2:I\$65185,8,FALSE))) part of the whole formula.

Do I need parantheses to distinguish this part of the formula as the false part of the first IF statement?

I can't seem to get around this.

##### MrExcel MVP
Make sure the dates are true dates, that is, numbers. First try to clean up with ASAP Utilities the lookup tables before considering any other possibilities.

Replies
9
Views
101
Replies
16
Views
311
Replies
6
Views
83
Replies
3
Views
79
Replies
10
Views
349