+ Reply to Thread
Results 1 to 14 of 14

Formula to pull the MIN date from a range, based on the criteria.

  1. #1
    Registered User
    Join Date
    01-11-2018
    Location
    New York, New York
    MS-Off Ver
    2010,2013,2016, 2019, 365
    Posts
    24

    Post Formula to pull the MIN date from a range, based on the criteria.

    New user here and not sure how to go about this.
    I have 2 sheets so far (plan on using more sheets but need to figure out this formula first) and I'm trying to get the MIN date based on the IF criteria. So my formula is this,
    {=MIN(IF(Detailed!$E$3:$E$279=E4,Detailed!$S$3:$S$279,0))}

    In my first cell it works perfectly fine, then I just drag it over and change MIN to MAX and it works fine again. But soon as I drag it down, the only value that changes is E4 to E5 to E6 and so on, which is what I want it to do. But, I get 1/0/1900, which is 0 in date form.

    I'm trying to figure out why "Detailed$E$3:$E$279" only shoots out elevator? Should there be a different formula for when I wanted a range to equal a cell?
    Attached Files Attached Files
    Last edited by Budhdr; 01-11-2018 at 10:45 AM.

  2. #2
    Forum Expert
    Join Date
    03-23-2004
    Location
    London, England
    MS-Off Ver
    Excel 2019
    Posts
    7,064

    Re: Formula to pull the MIN date from a range, based on the criteria.

    Category!L4 formula is spelt wrong. You have "Deatiled" instead of "Detailed"
    Regards
    Special-K

    Ensure you describe your problem clearly, I have little time available to solve these problems and do not appreciate numerous changes to them.

  3. #3
    Forum Expert
    Join Date
    05-05-2015
    Location
    UK
    MS-Off Ver
    Microsoft Excel for Microsoft 365 MSO (Version 2402 Build 16.0.17328.20068) 64-bit
    Posts
    28,198

    Re: Formula to pull the MIN date from a range, based on the criteria.

    Formulas should entered with Ctrl+Shift+Enter


    ...confirmed by pressing CTRL+SHIFT+ENTER to activate the array, not just ENTER. You will know the array is active when you see curly braces { } appear around your formula. If you do not CTRL+SHIFT+ENTER you will get an error or a clearly incorrect answer.


    They are not on posted w/book.

    Enter FIRST formula as above THEN drag down

  4. #4
    Forum Expert
    Join Date
    11-27-2007
    Location
    New Jersey, USA
    MS-Off Ver
    2013
    Posts
    1,669

    Re: Formula to pull the MIN date from a range, based on the criteria.

    I believe the problem is that the formulas aren't entered as Array.
    You need to enter first set of formulas in S3 and T3 with ctrl+shft+ent. Then drag them down. I tried it and it works.
    1. Click on the * Add Reputation if you think this helped you
    2. Mark your thread as SOLVED when question is resolved

    Modytrane

  5. #5
    Registered User
    Join Date
    01-11-2018
    Location
    New York, New York
    MS-Off Ver
    2010,2013,2016, 2019, 365
    Posts
    24

    Re: Formula to pull the MIN date from a range, based on the criteria.

    Quote Originally Posted by Special-K View Post
    Category!L4 formula is spelt wrong. You have "Deatiled" instead of "Detailed"
    I apologize, that wasn't suppose to be there I was just testing something. I should have been more specific. I am trying to get the formulas to work in the S and T column on the "Category" Sheet.

  6. #6
    Registered User
    Join Date
    01-11-2018
    Location
    New York, New York
    MS-Off Ver
    2010,2013,2016, 2019, 365
    Posts
    24

    Re: Formula to pull the MIN date from a range, based on the criteria.

    Quote Originally Posted by JohnTopley View Post
    Formulas should entered with Ctrl+Shift+Enter


    ...confirmed by pressing CTRL+SHIFT+ENTER to activate the array, not just ENTER. You will know the array is active when you see curly braces { } appear around your formula. If you do not CTRL+SHIFT+ENTER you will get an error or a clearly incorrect answer.


    They are not on posted w/book.

    Enter FIRST formula as above THEN drag down
    I did that and I'm getting back 1/0/1900

  7. #7
    Registered User
    Join Date
    01-11-2018
    Location
    New York, New York
    MS-Off Ver
    2010,2013,2016, 2019, 365
    Posts
    24

    Re: Formula to pull the MIN date from a range, based on the criteria.

    Quote Originally Posted by modytrane View Post
    I believe the problem is that the formulas aren't entered as Array.
    You need to enter first set of formulas in S3 and T3 with ctrl+shft+ent. Then drag them down. I tried it and it works.
    I rentered the formula, then click control + shift + enter but now it returned to 1/0/1900. Same exact formula.

  8. #8
    Forum Expert
    Join Date
    11-27-2007
    Location
    New Jersey, USA
    MS-Off Ver
    2013
    Posts
    1,669

    Re: Formula to pull the MIN date from a range, based on the criteria.

    see attached file.
    Attached Files Attached Files

  9. #9
    Registered User
    Join Date
    01-11-2018
    Location
    New York, New York
    MS-Off Ver
    2010,2013,2016, 2019, 365
    Posts
    24

    Re: Formula to pull the MIN date from a range, based on the criteria.

    @modytrane, @johntopley, @speacial-k

    I figure out my mistake I think, and it was working fine up until row 46 - 70 and then randomly doesn't work. I checked the spelling and it's fine. This is not working in the rows as stated before, in column S & T.

  10. #10
    Registered User
    Join Date
    01-11-2018
    Location
    New York, New York
    MS-Off Ver
    2010,2013,2016, 2019, 365
    Posts
    24

    Re: Formula to pull the MIN date from a range, based on the criteria.

    Quote Originally Posted by modytrane View Post
    see attached file.
    I appreciate that!

    But why is some of my dates returning back as 1/0/1900 on my spreadsheet and not yours?

    Mine: {=MAX(IF(Detailed!$E$3:$E$279=Category!E3,Detailed!$T$3:$T$279))}
    Yours: {=MAX(IF(Detailed!$E$3:$E$279=Category!E3,Detailed!$T$3:$T$279))}

    Mine: {=MIN(IF(Detailed!$E$3:$E$279=Category!E3,Detailed!$S$3:$S$279))}
    Yours: {=MIN(IF(Detailed!$E$3:$E$759=Category!E3,Detailed!$S$3:$S$759))}

  11. #11
    Forum Expert
    Join Date
    11-27-2007
    Location
    New Jersey, USA
    MS-Off Ver
    2013
    Posts
    1,669

    Re: Formula to pull the MIN date from a range, based on the criteria.

    See the attached file. I noticed formula in column T was wrong. I corrected it.
    Attached Files Attached Files

  12. #12
    Forum Expert
    Join Date
    03-23-2004
    Location
    London, England
    MS-Off Ver
    Excel 2019
    Posts
    7,064

    Re: Formula to pull the MIN date from a range, based on the criteria.

    You have blanks in Detailed!S518 and Detailed!S759
    Put a date in and this fixes the problem.
    Last edited by Special-K; 01-11-2018 at 10:35 AM.

  13. #13
    Forum Expert
    Join Date
    11-27-2007
    Location
    New Jersey, USA
    MS-Off Ver
    2013
    Posts
    1,669

    Re: Formula to pull the MIN date from a range, based on the criteria.

    can you post your file that shows 1/0/1900?

  14. #14
    Registered User
    Join Date
    01-11-2018
    Location
    New York, New York
    MS-Off Ver
    2010,2013,2016, 2019, 365
    Posts
    24

    Re: Formula to pull the MIN date from a range, based on the criteria.

    Quote Originally Posted by JohnTopley View Post
    Formulas should entered with Ctrl+Shift+Enter


    ...confirmed by pressing CTRL+SHIFT+ENTER to activate the array, not just ENTER. You will know the array is active when you see curly braces { } appear around your formula. If you do not CTRL+SHIFT+ENTER you will get an error or a clearly incorrect answer.


    They are not on posted w/book.

    Enter FIRST formula as above THEN drag down
    Quote Originally Posted by modytrane View Post
    can you post your file that shows 1/0/1900?
    Quote Originally Posted by Special-K View Post
    You have blanks in Detailed!S518 and Detailed!S759
    Put a date in and this fixes the problem.
    Welp. This is very embarrassing. I overlooked the numbers and didn't realize I I inputted 279 instead of 759. Very sorry about that. Once I fixed that, made it an array, and used your formulas. All is well! Thank you very much this will make my life much easier. Didn't know how crucial arrays will be. +Rep for all!

+ 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] IF/AND formula issue-Assiging date within range based on 1 criteria
    By hopegriffin in forum Excel Formulas & Functions
    Replies: 13
    Last Post: 03-11-2016, 05:11 PM
  2. Formula to pull data from one sheet to a new sheet based on date range
    By lisajolley11 in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 01-15-2015, 08:38 PM
  3. Formula to return values based on criteria and date range
    By jr217 in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 11-28-2014, 06:20 AM
  4. Formula for copying a entire row based on a date range criteria.
    By workallday in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 10-23-2012, 01:09 AM
  5. Replies: 6
    Last Post: 09-12-2011, 12:51 PM
  6. Based on date, pull sum from a range of cells?
    By infinitysales in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 05-23-2008, 06:08 PM
  7. Pull Data based on a date criteria
    By Nolesphan30 in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 02-01-2008, 12:22 AM

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