+ Reply to Thread
Results 1 to 7 of 7

Pull list of dates that are greater than a certain date (meets criteria)

  1. #1
    Registered User
    Join Date
    06-24-2013
    Location
    RTP, USA
    MS-Off Ver
    Excel 2007 and 2010
    Posts
    2

    Pull list of dates that are greater than a certain date (meets criteria)

    Hi everybody,

    So I've got a vertical list of dates in M/D/YYYY format, and I'm trying to come up with a method to pull certain dates that are greater than a given benchmark and paste those values in another column. For instance, if I've got a list with 3/3/2008, 5/5/2010, 6/6/2011, and 7/7/2012 I want to pull only the dates beyond 12/31/2010 (so would be the 6/6 and 7/7 ones).

    I'm assuming this isn't doable with one formula, so I would need a macro. But I'm having trouble just even coming up with the logical operator for just one date. I must be doing something wrong here. If my date in B2 is 1/1/2009 and I have a formula as IF(B2>12/31/2009,"True","False"), I just get TRUE, which shouldn't be the case.

    I'm pretty new at Excel (I wrote my first "big" macro yesterday) so any help would be much appreciated!

  2. #2
    Forum Expert Sam Capricci's Avatar
    Join Date
    06-14-2012
    Location
    Palm Harbor, Florida
    MS-Off Ver
    16.84 for Mac MS 365
    Posts
    8,499

    Re: Pull list of dates that are greater than a certain date (meets criteria)

    Instead of doing the IF(B2>12/31/2010,"TRUE","False") you could write if(B2>12/31/2010,B2,"") then it would return the value in B2 if it exceeds your value.

  3. #3
    Registered User
    Join Date
    06-24-2013
    Location
    RTP, USA
    MS-Off Ver
    Excel 2007 and 2010
    Posts
    2

    Re: Pull list of dates that are greater than a certain date (meets criteria)

    Hmm, that still seems to not work for me--no matter what, the TRUE condition is returned. I've found a workaround to the original question though, so this becomes more of an interesting question to me than a need-to-know. I'll keep hunting for an answer.

  4. #4
    Valued Forum Contributor wenqq3's Avatar
    Join Date
    04-01-2013
    Location
    Malaysia
    MS-Off Ver
    Excel 2003
    Posts
    868

    Re: Pull list of dates that are greater than a certain date (meets criteria)

    Hi flamewheel, welcome to Forum.
    Can you upload a sample workbook with remove those sensitive data.
    Post a WORKBOOK.
    To attach a file, push the button with the paperclip (or scroll down to the Manage Attachments button), browse to the required file, and then push the Upload button.
    -If the problem is solved, please mark your thread as Solved: Click Thread Tools above your first post, select "Mark your thread as Solved".

    -Always upload a workbook before start your question
    To attach a file, push the button with the paperclip (or scroll down to the Manage Attachments button), browse to the required file, and then push the Upload button.

    +++ If my answer(s) helped you, please add me reputation by click on * +++

  5. #5
    Forum Contributor
    Join Date
    06-26-2013
    Location
    LAX
    MS-Off Ver
    Excel 2007,Excel 2010
    Posts
    363

    Re: Pull list of dates that are greater than a certain date (meets criteria)

    Hi,

    I assume you are having excel 2007 or above. Can't we just use date filters and get the desired results.

    See this Pull list of dates.xlsxsheet. Will that work?

  6. #6
    Forum Expert Sam Capricci's Avatar
    Join Date
    06-14-2012
    Location
    Palm Harbor, Florida
    MS-Off Ver
    16.84 for Mac MS 365
    Posts
    8,499

    Re: Pull list of dates that are greater than a certain date (meets criteria)

    Unfortunately my excel was down when I wrote the reply so I didn't have a chance to test it. Now that I did, I find that I had to put in a helper cell to get it to work.
    So for example, say the dates are in column A starting at A2, I put in Cell B1 12/31/2010 then wrote in cells B2 and down =If(A2>$B$1,A2,"") and everywhere that the date is equal to or less than 12/31/2010 it returns the cell value (numeric, just change it to date, e.g. 40700 which is 6/6/2011) or returns a blank. Worked for me.

  7. #7
    Forum Expert Sam Capricci's Avatar
    Join Date
    06-14-2012
    Location
    Palm Harbor, Florida
    MS-Off Ver
    16.84 for Mac MS 365
    Posts
    8,499

    Re: Pull list of dates that are greater than a certain date (meets criteria)

    Also found it will work coded into the formula without a helper cell if you write the date as a number. So if the date you want to see exceeded is 12/31/2010, numerically that is 40543 so if you write the formula as =if(A2>40543,A2,"") and make sure the cell you write that in is formatted as date, it will work returning either the cell in column A or a blank.

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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