+ Reply to Thread
Results 1 to 8 of 8

Finding rows where dates are within specified date range

  1. #1
    Registered User
    Join Date
    06-08-2020
    Location
    Finland
    MS-Off Ver
    1809
    Posts
    4

    Question Finding rows where dates are within specified date range

    Hi,
    I have a data table where there are start and end date specified for each row. I would need to find all those rows where there is any number of days within year 2020 between the start date and end date. My table looks like this:

    StartEndDate_table_exaple.jpg

    Basically, the only record I'm not interested in is on row 5. I need support in figuring out the best formula to achieve this. Any ideas?

    Br, Heini

  2. #2
    Valued Forum Contributor
    Join Date
    03-24-2020
    Location
    Thailand
    MS-Off Ver
    Office 2016
    Posts
    897

    Re: Finding rows where dates are within specified date range

    Hi Heini,

    Try this in D2: =IF(OR(YEAR(B2)=2020,YEAR(C2)=2020),"in 2020","No days in 2020")

  3. #3
    Forum Expert
    Join Date
    12-23-2006
    Location
    germany
    MS-Off Ver
    XL2003 / 2007 / 2010
    Posts
    6,326

    Re: Finding rows where dates are within specified date range

    Hi
    and when found what should happen? Highlight them, extract them?
    Have you tried a filter ?

  4. #4
    Registered User
    Join Date
    06-08-2020
    Location
    Finland
    MS-Off Ver
    1809
    Posts
    4

    Re: Finding rows where dates are within specified date range

    Thanks ORoos for a quick reply.
    With the suggested formula =IF(OR(YEAR(B2)=2020,YEAR(C2)=2020),"in 2020","No days in 2020") it does not unfortunately catch row 8 where actually the entire year 2020 is within the range of start and end date.

  5. #5
    Forum Expert
    Join Date
    12-23-2006
    Location
    germany
    MS-Off Ver
    XL2003 / 2007 / 2010
    Posts
    6,326

    Re: Finding rows where dates are within specified date range

    Then try
    Formula: copy to clipboard
    Please Login or Register  to view this content.


    Adding a small sample sheet instead of a picture helps ( see yellow banner)

  6. #6
    Registered User
    Join Date
    06-08-2020
    Location
    Finland
    MS-Off Ver
    1809
    Posts
    4

    Re: Finding rows where dates are within specified date range

    Quote Originally Posted by arthurbr View Post
    Hi
    and when found what should happen? Highlight them, extract them?
    Have you tried a filter ?
    Once I have found all the rows where there is a touchpoint to year 2020, I will extract them for further processing.

  7. #7
    Registered User
    Join Date
    06-08-2020
    Location
    Finland
    MS-Off Ver
    1809
    Posts
    4

    Re: Finding rows where dates are within specified date range

    Quote Originally Posted by arthurbr View Post
    Then try
    Formula: copy to clipboard
    Please Login or Register  to view this content.


    Adding a small sample sheet instead of a picture helps ( see yellow banner)
    Thank you arthurbr! This formula did the trick!

  8. #8
    Forum Expert
    Join Date
    12-23-2006
    Location
    germany
    MS-Off Ver
    XL2003 / 2007 / 2010
    Posts
    6,326

    Re: Finding rows where dates are within specified date range

    You're welcome

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. [SOLVED] Finding Dates Within Date Range (Based on Today's Date) Whilst Matching Name?
    By EduardStoo in forum Excel Formulas & Functions
    Replies: 9
    Last Post: 02-08-2019, 10:31 AM
  2. Replies: 1
    Last Post: 04-06-2016, 07:02 AM
  3. Replies: 1
    Last Post: 11-25-2014, 07:26 PM
  4. Replies: 2
    Last Post: 08-19-2013, 06:00 AM
  5. Replies: 8
    Last Post: 02-27-2009, 06:06 PM
  6. Finding Dates in a date range
    By Marcus in forum Excel General
    Replies: 1
    Last Post: 04-04-2005, 09:06 PM
  7. [SOLVED] Finding dates within a date range
    By Marcus in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 04-04-2005, 09:06 PM

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1