Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 9
Default Nested IF with a VLOOKUP?

I have 2 workbooks: stores.xls and sales.xls. Both sheets have a column that
contain a store number. stores.xls also has gross sales listed in column F.

The formula will reside in sales.xls (column G for each row). What I need to
do is compare [sales.xls]A2 to column C in stores.xls and find a match. After
it finds a match, I need it to return cell F [stores.xls] in the same row.

Because there are some cells that will be a null value, I need them to
return blank.

I was thinking that this would be a nested IF statement with a VLOOKUP, but
I wasn't sure if that was efficient or the only way. Please help if you have
any ideas.

Thanks!
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 1,047
Default Nested IF with a VLOOKUP?

hi Plunk,

=if(iserror(vlookup([sales.xls]sheet1!a2,[stores.xls]sheet1!c2:f1000,3,0)),"",vlookup([sales.xls]sheet1!a2,[stores.xls]sheet1!c2:f1000,3,0))

hth
regards from Brazil



"plunk25" escreveu:

I have 2 workbooks: stores.xls and sales.xls. Both sheets have a column that
contain a store number. stores.xls also has gross sales listed in column F.

The formula will reside in sales.xls (column G for each row). What I need to
do is compare [sales.xls]A2 to column C in stores.xls and find a match. After
it finds a match, I need it to return cell F [stores.xls] in the same row.

Because there are some cells that will be a null value, I need them to
return blank.

I was thinking that this would be a nested IF statement with a VLOOKUP, but
I wasn't sure if that was efficient or the only way. Please help if you have
any ideas.

Thanks!

  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 195
Default Nested IF with a VLOOKUP?

Hi,

This might help you:

=IF(ISERROR(VLOOKUP(.....)),"",VLOOKUP(.....))

If the function has some error in it, if will return an empty cell
otherwise the corresponding value for the VLOOKUPed value.

Thanks.

Shail




plunk25 wrote:

I have 2 workbooks: stores.xls and sales.xls. Both sheets have a column that
contain a store number. stores.xls also has gross sales listed in column F.

The formula will reside in sales.xls (column G for each row). What I need to
do is compare [sales.xls]A2 to column C in stores.xls and find a match. After
it finds a match, I need it to return cell F [stores.xls] in the same row.

Because there are some cells that will be a null value, I need them to
return blank.

I was thinking that this would be a nested IF statement with a VLOOKUP, but
I wasn't sure if that was efficient or the only way. Please help if you have
any ideas.

Thanks!


  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 10,593
Default Nested IF with a VLOOKUP?

=IF(ISNA(VLOOKUP(A2,[stores.xls]Sheet1!$C$1000:$F$1000,4,FALSE)),"",VLOOKUP(
A2,[stores.xls]Sheet1!$C$1000:$F$1000,4,FALSE))

--
HTH

Bob Phillips

(replace somewhere in email address with gmail if mailing direct)

"plunk25" wrote in message
...
I have 2 workbooks: stores.xls and sales.xls. Both sheets have a column

that
contain a store number. stores.xls also has gross sales listed in column

F.

The formula will reside in sales.xls (column G for each row). What I need

to
do is compare [sales.xls]A2 to column C in stores.xls and find a match.

After
it finds a match, I need it to return cell F [stores.xls] in the same row.

Because there are some cells that will be a null value, I need them to
return blank.

I was thinking that this would be a nested IF statement with a VLOOKUP,

but
I wasn't sure if that was efficient or the only way. Please help if you

have
any ideas.

Thanks!



  #5   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 176
Default Nested IF with a VLOOKUP?

Marcelo - I believe your vlookup's column index number should be 4:

=if(iserror(vlookup([sales.xls]sheet1!a2,[stores.xls]sheet1!c2:f1000,4,0)),"",vlookup([sales.xls]sheet1!a2,[stores.xls]sheet1!c2:f1000,4,0))

--
Regards,
Dave


"Marcelo" wrote:

hi Plunk,

=if(iserror(vlookup([sales.xls]sheet1!a2,[stores.xls]sheet1!c2:f1000,3,0)),"",vlookup([sales.xls]sheet1!a2,[stores.xls]sheet1!c2:f1000,3,0))

hth
regards from Brazil



"plunk25" escreveu:

I have 2 workbooks: stores.xls and sales.xls. Both sheets have a column that
contain a store number. stores.xls also has gross sales listed in column F.

The formula will reside in sales.xls (column G for each row). What I need to
do is compare [sales.xls]A2 to column C in stores.xls and find a match. After
it finds a match, I need it to return cell F [stores.xls] in the same row.

Because there are some cells that will be a null value, I need them to
return blank.

I was thinking that this would be a nested IF statement with a VLOOKUP, but
I wasn't sure if that was efficient or the only way. Please help if you have
any ideas.

Thanks!



  #6   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 1,047
Default Nested IF with a VLOOKUP?

yeah David, my mistake

regards


"David Billigmeier" escreveu:

Marcelo - I believe your vlookup's column index number should be 4:

=if(iserror(vlookup([sales.xls]sheet1!a2,[stores.xls]sheet1!c2:f1000,4,0)),"",vlookup([sales.xls]sheet1!a2,[stores.xls]sheet1!c2:f1000,4,0))

--
Regards,
Dave


"Marcelo" wrote:

hi Plunk,

=if(iserror(vlookup([sales.xls]sheet1!a2,[stores.xls]sheet1!c2:f1000,3,0)),"",vlookup([sales.xls]sheet1!a2,[stores.xls]sheet1!c2:f1000,3,0))

hth
regards from Brazil



"plunk25" escreveu:

I have 2 workbooks: stores.xls and sales.xls. Both sheets have a column that
contain a store number. stores.xls also has gross sales listed in column F.

The formula will reside in sales.xls (column G for each row). What I need to
do is compare [sales.xls]A2 to column C in stores.xls and find a match. After
it finds a match, I need it to return cell F [stores.xls] in the same row.

Because there are some cells that will be a null value, I need them to
return blank.

I was thinking that this would be a nested IF statement with a VLOOKUP, but
I wasn't sure if that was efficient or the only way. Please help if you have
any ideas.

Thanks!

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Nested Vlookup and IF function???? Simon Lloyd Excel Worksheet Functions 6 May 14th 06 10:21 PM
Complex Vlookup and List Validation and Nested IF statements Bobby Excel Worksheet Functions 2 March 9th 06 05:37 PM
Can Someone Help me With a Nested VLOOKUP [email protected] Excel Discussion (Misc queries) 1 December 17th 05 02:24 PM
Nested IF Function and VLookup Alternatives robert.holmes Excel Worksheet Functions 1 December 12th 05 10:28 PM
Nested Vlookup or alternative? scoobydoo99 Excel Worksheet Functions 2 October 28th 05 02:38 PM


All times are GMT +1. The time now is 12:32 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"