P
Paul Simon
For each record within an Excel database, column D will either be the
value of column C, or, if column C is blank, the value of a Vlookup
based on column B. However, if that Vlookup would generate either a
#NA or a 0, column D is to be blank.
This formula in column D (cell D2 in this example) works, but makes 3
passes of the Vlookup.
=if(C2<>"",C2,if(or(isna(vlookup($B2,Sheet2!$A$2:$B$20,2,false)),vlookup($B2,Sheet2!$A$2:$B$20,2,false)=0),"",vlookup($B2,Sheet2!$A$2:$B$20,2,false)))
Is there a more efficient solution?
Many thanks,
Paul
value of column C, or, if column C is blank, the value of a Vlookup
based on column B. However, if that Vlookup would generate either a
#NA or a 0, column D is to be blank.
This formula in column D (cell D2 in this example) works, but makes 3
passes of the Vlookup.
=if(C2<>"",C2,if(or(isna(vlookup($B2,Sheet2!$A$2:$B$20,2,false)),vlookup($B2,Sheet2!$A$2:$B$20,2,false)=0),"",vlookup($B2,Sheet2!$A$2:$B$20,2,false)))
Is there a more efficient solution?
Many thanks,
Paul