+ Reply to Thread
Results 1 to 19 of 19

Extract the minimum and second lowest numbers from an array with multiple criteria

  1. #1
    Valued Forum Contributor
    Join Date
    04-27-2015
    Location
    Abu Dhabi, U.A.E
    MS-Off Ver
    Office 365 | 2016
    Posts
    696

    Extract the minimum and second lowest numbers from an array with multiple criteria

    Back with a question
    I am looking for a formula to extract the minimum and second lowest values from an array if there are multiple criteria like below:

    Extract the minimum value from array, say A3:F3 - Note: between these cells there are texts.
    We need to consider only the cells if the adjacent cell has text and also the relevant column header is "Unit Price- AD"Untitled.jpg

    Need similar formula for 2nd lowest.

  2. #2
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,851

    Re: Extract the minimum and second lowest numbers from an array with multiple criteria

    Will you please attach a sample Excel workbook? We are not able to work with or manipulate a picture of one.

    1. Make sure that your sample data are REPRESENTATIVE of your real data. The use of unrepresentative data is very frustrating and can lead to long delays in reaching a solution.

    2. Make sure that your desired solution is also shown (mock up the results manually).

    3. Make sure that all confidential data is removed or replaced with dummy data first (e.g. names, addresses, E-mails, etc.).

    4. Try to avoid using merged cells as they cause lots of problems.

    Unfortunately the attachment icon doesn't work at the moment, so to attach an Excel file you have to do the following: just before posting, scroll down to Go Advanced and then scroll down to Manage Attachments. Now follow the instructions at the top of that screen.

    Please pay particular attention to point 2 (above): without an idea of your intended outcomes, it is often very difficult to offer appropriate advice.
    Ali


    Enthusiastic self-taught user of MS Excel who's always learning!
    Don't forget to say "thank you" in your thread to anyone who has offered you help.
    You can reward them by clicking on * Add Reputation below their user name on the left, if you wish.

    Forum Rules (updated August 2023): please read them here.

  3. #3
    Forum Expert avk's Avatar
    Join Date
    07-12-2007
    Location
    India
    MS-Off Ver
    Microsoft Office 2013
    Posts
    3,223

    Re: Extract the minimum and second lowest numbers from an array with multiple criteria

    Try with
    Formula: copy to clipboard
    Please Login or Register  to view this content.


    atul


    If my answer (or that of other members) has helped you, please say "Thanks" by clicking the Add Reputation button at the foot of one of their posts.

    Also: if your problem is solved, please take the time to mark your thread as SOLVED by going to the top of your first post, selecting "Thread Tools" and then "Mark thread as solved".

  4. #4
    Valued Forum Contributor
    Join Date
    04-27-2015
    Location
    Abu Dhabi, U.A.E
    MS-Off Ver
    Office 365 | 2016
    Posts
    696

    Re: Extract the minimum and second lowest numbers from an array with multiple criteria

    Not able to attach the file. Some IT issues.

  5. #5
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,851

    Re: Extract the minimum and second lowest numbers from an array with multiple criteria

    What IT issues? If you mean the paperclip icon, it doesn't work, as I explained in my post. I also explained what does work.

    Have you tried AVK's suggestion?

  6. #6
    Forum Guru
    Join Date
    02-27-2016
    Location
    Vietnam
    MS-Off Ver
    2016
    Posts
    5,911

    Re: Extract the minimum and second lowest numbers from an array with multiple criteria

    Maybe?

    =SMALL(IF($A$2:$U$2="Unit Price- AD",A3:U3),1)

    Enter with Ctrl+Shift+Enter.

  7. #7
    Valued Forum Contributor
    Join Date
    04-27-2015
    Location
    Abu Dhabi, U.A.E
    MS-Off Ver
    Office 365 | 2016
    Posts
    696

    Re: Extract the minimum and second lowest numbers from an array with multiple criteria

    Still not able to upload the file. I cannot see Manage attachments option

  8. #8
    Forum Expert avk's Avatar
    Join Date
    07-12-2007
    Location
    India
    MS-Off Ver
    Microsoft Office 2013
    Posts
    3,223

    Re: Extract the minimum and second lowest numbers from an array with multiple criteria

    Click on GO ADVANCED and then scroll down to Manage Attachments to open the upload window.
    Clcik on Choose File : From your respected folder select file & click on "open"
    >Click on "upload" tab
    >After completed upload, click on "close this window
    >Click on "Submit Reply"

  9. #9
    Valued Forum Contributor
    Join Date
    04-27-2015
    Location
    Abu Dhabi, U.A.E
    MS-Off Ver
    Office 365 | 2016
    Posts
    696

    Re: Extract the minimum and second lowest numbers from an array with multiple criteria

    Here you go
    Attached Files Attached Files

  10. #10
    Forum Expert avk's Avatar
    Join Date
    07-12-2007
    Location
    India
    MS-Off Ver
    Microsoft Office 2013
    Posts
    3,223

    Re: Extract the minimum and second lowest numbers from an array with multiple criteria

    You ask "Extract the minimum and second lowest numbers"
    Where as per attach file you asking extract as per "Unit Pirce-AD"
    Can you manually enter your required result & where (in which cell) confirm.

  11. #11
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,851

    Re: Extract the minimum and second lowest numbers from an array with multiple criteria

    Perhaps this:

    Excel 2016 (Windows) 32 bit
    E
    5
    =MAX(IF(B3:I3<>"",IF(C3:J3<>"-",IF(ISNUMBER(C3:J3)=FALSE,B3:I3))))
    Sheet: Sheet1

    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.

  12. #12
    Valued Forum Contributor
    Join Date
    04-27-2015
    Location
    Abu Dhabi, U.A.E
    MS-Off Ver
    Office 365 | 2016
    Posts
    696

    Re: Extract the minimum and second lowest numbers from an array with multiple criteria

    Please look at the upper row. there are 4 vendors which I mentioned in the top row.
    I need to get the minimum and second lowest values of 'Unit Price-AD' only if there is a TEXT in 'Remarks' (adjacent cell).

  13. #13
    Valued Forum Contributor
    Join Date
    04-27-2015
    Location
    Abu Dhabi, U.A.E
    MS-Off Ver
    Office 365 | 2016
    Posts
    696

    Re: Extract the minimum and second lowest numbers from an array with multiple criteria

    Quote Originally Posted by AliGW View Post
    Perhaps this:

    Excel 2016 (Windows) 32 bit
    E
    5
    =MAX(IF(B3:I3<>"",IF(C3:J3<>"-",IF(ISNUMBER(C3:J3)=FALSE,B3:I3))))
    Sheet: Sheet1

    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.
    It doesn't work properly. I have already tried this.
    Even if you removed the remarks "GE" in the adjacent cell, you will get the same value "3".

  14. #14
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,851

    Re: Extract the minimum and second lowest numbers from an array with multiple criteria

    What should the answer be if that cell is blank?

  15. #15
    Valued Forum Contributor
    Join Date
    04-27-2015
    Location
    Abu Dhabi, U.A.E
    MS-Off Ver
    Office 365 | 2016
    Posts
    696

    Re: Extract the minimum and second lowest numbers from an array with multiple criteria

    Blank or Zero.

  16. #16
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,851

    Re: Extract the minimum and second lowest numbers from an array with multiple criteria

    This maybe?

    Excel 2016 (Windows) 32 bit
    E
    5
    =MAX(IF(B3:I3<>"",IF(B2:I2="Unit Pirce-AD",IF(C3:J3<>"-",IF(C3:J3<>"",IF(ISTEXT(C3:J3)=TRUE,B3:I3))))))
    Sheet: Sheet1

    using CTRL+SHIFT+ENTER.

  17. #17
    Forum Moderator vlady's Avatar
    Join Date
    09-22-2011
    Location
    Philippines - OLSHCO -Guimba-Nueva Ecija
    MS-Off Ver
    2021
    Posts
    4,361

    Re: Extract the minimum and second lowest numbers from an array with multiple criteria

    From Ali's Formula in #11 this will work for all text like GE and KLT

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


    IF the structure of your data are all the same

    you have

    Unit Pirce-AD Unit Pirce-DXB Remarks

    FOR EVERY VENDOR
    Attached Files Attached Files
    I think people forget the word "THANK YOU!!!!" Do you still know it???

    There is a little star ( ADD REPUTATION ) below those person who helped you. Click it to say your "PRIVATE APPRECIATION TO THEIR EFFORT ON THEIR CONTRIBUTIONS "

    Regards,
    Vladimir

  18. #18
    Forum Expert avk's Avatar
    Join Date
    07-12-2007
    Location
    India
    MS-Off Ver
    Microsoft Office 2013
    Posts
    3,223

    Re: Extract the minimum and second lowest numbers from an array with multiple criteria

    I think this you required.
    If "Unit Pirce-AD" find & extract second lowest number.
    In "C5" criteria : Unit Pirce-AD
    In "D5" Formula :
    Formula: copy to clipboard
    Please Login or Register  to view this content.

  19. #19
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,851

    Re: Extract the minimum and second lowest numbers from an array with multiple criteria

    Thanks for the rep - glad to have helped!

+ 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] Highest to lowest results using multiple data with array formula
    By Jacolene in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 04-23-2016, 04:32 AM
  2. Replies: 12
    Last Post: 03-13-2016, 01:20 PM
  3. Recording lowest and 2nd lowest numbers in a rang of cells
    By ORIELSON in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 07-01-2015, 10:31 AM
  4. Extract a list of numbers under multiple criteria to another workbook
    By lks0912 in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 02-15-2013, 08:03 AM
  5. [SOLVED] Extract 1st and 2nd minimum numbers from a column
    By bobboy in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 01-16-2013, 05:25 PM
  6. Replies: 5
    Last Post: 06-21-2012, 10:36 AM
  7. Finding lowest cost price with multiple criteria
    By jimbokeep in forum Excel General
    Replies: 8
    Last Post: 06-30-2010, 01:11 PM

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