ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   Vlookup (https://www.excelbanter.com/excel-discussion-misc-queries/210093-vlookup.html)

Ron St Jean

Vlookup
 
I am trying to look up 2 dates (start and finish) I am using vlookup but it
seems that I can only have one date. I have created a calendar for my
project. Here is the formula I am using that works for one date. How would I
modify it to use both dates?
=VLOOKUP($D2,$CA$2:$CA$38,1,FALSE)
I am trying to make it so that it would be something like
=VLOOKUP($D2:E2,$CA$2:$CA$38,1,FALSE)

KC Rippstein hotmail com>

Vlookup
 
Can you give more info? Is D2 your desired start date to search for and E2
your desired end date to search for? Is the start date always in column CA?
What column has the end date? Your VLOOKUP is looking up a date and then
returning that date (returning column 1 returns the same thing you searched
for as instructed in D2, so how is that helpful?).

I believe you will eventually want to use SUMPRODUCT instead of VLOOKUP.
--
Please remember to indicate when the post is answered so others can benefit
from it later.


"Ron St Jean" wrote:

I am trying to look up 2 dates (start and finish) I am using vlookup but it
seems that I can only have one date. I have created a calendar for my
project. Here is the formula I am using that works for one date. How would I
modify it to use both dates?
=VLOOKUP($D2,$CA$2:$CA$38,1,FALSE)
I am trying to make it so that it would be something like
=VLOOKUP($D2:E2,$CA$2:$CA$38,1,FALSE)


Ron St Jean

Vlookup
 
D2 is my desired start date, and E2 is my desired finish date. Column CA is
Jan 1-31, so I am trying to see if my start date or finish date is in
January, I then want to drag the same formula to look in February, March, etc

"KC Rippstein" wrote:

Can you give more info? Is D2 your desired start date to search for and E2
your desired end date to search for? Is the start date always in column CA?
What column has the end date? Your VLOOKUP is looking up a date and then
returning that date (returning column 1 returns the same thing you searched
for as instructed in D2, so how is that helpful?).

I believe you will eventually want to use SUMPRODUCT instead of VLOOKUP.
--
Please remember to indicate when the post is answered so others can benefit
from it later.


"Ron St Jean" wrote:

I am trying to look up 2 dates (start and finish) I am using vlookup but it
seems that I can only have one date. I have created a calendar for my
project. Here is the formula I am using that works for one date. How would I
modify it to use both dates?
=VLOOKUP($D2,$CA$2:$CA$38,1,FALSE)
I am trying to make it so that it would be something like
=VLOOKUP($D2:E2,$CA$2:$CA$38,1,FALSE)


MyVeryOwnSelf[_2_]

Vlookup
 
D2 is my desired start date, and E2 is my desired finish date. Column
CA is Jan 1-31, so I am trying to see if my start date or finish date
is in January, I then want to drag the same formula to look in
February, March, etc


Here's one way, but it doesn't use a lookup.

In a column of your choice, put this in row 1 and copy down to row 12:
=TEXT(DATE(2000,ROW(),1),"Mmmm")&
" "&
IF(MONTH($D$2)=ROW(),"Start ","")&
IF(MONTH($E$2)=ROW(),"End ","")

Modify to suit.


All times are GMT +1. The time now is 08:19 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com