Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 343
Default Problem working with Vlookup

I have the following table (A1:B6) from which I want to return the
appropriate value from column 1. This is my formula:

VLOOKUP(R16,'Sunday (3)'!A1:B6,1,TRUE)

My problem is that if R16 contains AIL, Floating Holiday, LWOP, Regular
Holiday the formula returns #NA, Sick returns NW6 not NW5 and Vacation
returns the correct value NW6.

As a test I tried swapping Vacation and LWOP and but Vacation Still returned
the NW6 value.


A B
1 NW1 AIL
2 NW2 Floating Holiday
3 NW3 LWOP
4 NW4 Regular Holiday
5 NW5 Sick
6 NW6 Vacation

  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 22,906
Default Problem working with Vlookup

I'm surprised you get any return other than an error with that construct.

VLOOKUP won't look left.

Swap columns A and B then =VLOOKUP(R16,'Sunday (3)'!$A$1:$B$6,2,TRUE)


Gord Dibben MS Excel MVP

On Sat, 16 May 2009 11:07:01 -0700, "Patrick C. Simonds"
wrote:

I have the following table (A1:B6) from which I want to return the
appropriate value from column 1. This is my formula:

VLOOKUP(R16,'Sunday (3)'!A1:B6,1,TRUE)

My problem is that if R16 contains AIL, Floating Holiday, LWOP, Regular
Holiday the formula returns #NA, Sick returns NW6 not NW5 and Vacation
returns the correct value NW6.

As a test I tried swapping Vacation and LWOP and but Vacation Still returned
the NW6 value.


A B
1 NW1 AIL
2 NW2 Floating Holiday
3 NW3 LWOP
4 NW4 Regular Holiday
5 NW5 Sick
6 NW6 Vacation


  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 15,768
Default Problem working with Vlookup

Try it like this:

=INDEX('Sunday (3)'!A1:A6,MATCH(R16,'Sunday (3)'!B1:B6,0))


--
Biff
Microsoft Excel MVP


"Patrick C. Simonds" wrote in message
...
I have the following table (A1:B6) from which I want to return the
appropriate value from column 1. This is my formula:

VLOOKUP(R16,'Sunday (3)'!A1:B6,1,TRUE)

My problem is that if R16 contains AIL, Floating Holiday, LWOP, Regular
Holiday the formula returns #NA, Sick returns NW6 not NW5 and Vacation
returns the correct value NW6.

As a test I tried swapping Vacation and LWOP and but Vacation Still
returned the NW6 value.


A B
1 NW1 AIL
2 NW2 Floating Holiday
3 NW3 LWOP
4 NW4 Regular Holiday
5 NW5 Sick
6 NW6 Vacation



  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 265
Default Problem working with Vlookup

In article ,
"Patrick C. Simonds" wrote:

I have the following table (A1:B6) from which I want to return the
appropriate value from column 1. This is my formula:

VLOOKUP(R16,'Sunday (3)'!A1:B6,1,TRUE)

My problem is that if R16 contains AIL, Floating Holiday, LWOP, Regular
Holiday the formula returns #NA, Sick returns NW6 not NW5 and Vacation
returns the correct value NW6.

As a test I tried swapping Vacation and LWOP and but Vacation Still returned
the NW6 value.


A B
1 NW1 AIL
2 NW2 Floating Holiday
3 NW3 LWOP
4 NW4 Regular Holiday
5 NW5 Sick
6 NW6 Vacation



Try...

=INDEX('Sunday (3)'!A1:A6,MATCH(R16,'Sunday (3)'!B1:B6,0))

--
Domenic
http://www.xl-central.com
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
vlookup not working Juan Excel Worksheet Functions 3 January 22nd 09 12:51 AM
VLOOKUP not working Teri Excel Discussion (Misc queries) 1 May 25th 08 06:16 PM
Vlookup not working japc90 Excel Discussion (Misc queries) 6 April 5th 08 01:40 AM
VLOOKUP not working Small One Excel Discussion (Misc queries) 4 May 31st 07 05:42 PM
VLOOKUP not working??? Gary Excel Worksheet Functions 7 March 1st 07 11:34 PM


All times are GMT +1. The time now is 01:54 PM.

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

About Us

"It's about Microsoft Excel"