+ Reply to Thread
Results 1 to 7 of 7

Using Excel 2010 with multiple "if" & need all results in one cell, can't use textjoin

  1. #1
    Registered User
    Join Date
    05-10-2012
    Location
    USA
    MS-Off Ver
    Excel 365
    Posts
    41

    Using Excel 2010 with multiple "if" & need all results in one cell, can't use textjoin

    Hi! I have Excel 2010 at work and am trying to create a report because the app they use can't do it. The original data was pulled from 5 different reports and have now have everything needed on two sheets. I have 3 criteria:
    'MRP9202'!M:M>C2 'MRP9202'!B:B=G2 and 'MRP9202'!Q:Q<R2

    and need to return all conforming values from 'MRP9202'!R:R (a 'helper column', which concatenates columns N, J and P) and display them in one cell, separated with commas or pipes.

    I tried all sorts of IF/AND and INDEX/MATCH formulas, and the closest to success was =IF(AND('MRP9202'!M:M>C2,'MRP9202'!B:B=G2,'MRP9202'!Q:Q<R2), CONCATENATE('MRP9202'!N:N," Needs QTY:",'MRP9202'!J:J," Ships:",'MRP9202'!P:P),"") but it only returns the first valid option and I need all of them.

    I created the helper column 'MRP9202'!R:R in the interest of simplicity for the INDEX/MATCH attempts, but gladly abandon it if another method works. Everything, formula or array, I've tried only returns the first valid option.

    Thanks, in advance, for any help you can provide!

    ***added a sanitized version of the spreadsheet
    Attached Files Attached Files
    Last edited by arcarc1309; 02-24-2020 at 07:29 PM.

  2. #2
    Forum Expert JBeaucaire's Avatar
    Join Date
    03-21-2004
    Location
    Bakersfield, CA
    MS-Off Ver
    2010, 2016, Office 365
    Posts
    33,492

    Re: Using Excel 2010 with multiple "if" & need all results in one cell, can't use textjoin

    If you need ONE of these formulas for use in ONE lookup, it's going to be simple with a helper column added to the data sheet.

    If what you need is the same thing you've described over and over again starting at row2 and going downward ad nauseum... that's not going to be easy with a simple formula.

    If you're allowed to use VBA we could create a custom function for you to install into your workbook that would then function like a formula, just a special one we created with coding.
    _________________
    Microsoft MVP 2010 - Excel
    Visit: Jerry Beaucaire's Excel Files & Macros

    If you've been given good help, use the icon below to give reputation feedback, it is appreciated.
    Always put your code between code tags. [CODE] your code here [/CODE]

    ?None of us is as good as all of us? - Ray Kroc
    ?Actually, I *am* a rocket scientist.? - JB (little ones count!)

  3. #3
    Forum Guru MarvinP's Avatar
    Join Date
    07-23-2010
    Location
    Woodinville, WA
    MS-Off Ver
    Office 365
    Posts
    16,384

    Re: Using Excel 2010 with multiple "if" & need all results in one cell, can't use textjoin

    Hi arcarc and welcome to the forum,

    I'd use the Advanced Filter tool that is in the Data tab. See the attached example that has 100 rows of data, a criteria area and the answer to the right. Instead of exact matches you would use your criteria above and this should then give all possible answers.

    Advanced Filter using 3 Column AND.xlsx

    Marv
    One test is worth a thousand opinions.
    Click the * Add Reputation below to say thanks.

  4. #4
    Registered User
    Join Date
    05-10-2012
    Location
    USA
    MS-Off Ver
    Excel 365
    Posts
    41

    Re: Using Excel 2010 with multiple "if" & need all results in one cell, can't use textjoin

    Jerry,

    Thanks! I'm not opposed to VBA, as long as I know how & why it works. I've spent the last 3 months learning excel from scratch after being "volunteered" for a position at work, so I know enough to be dangerous! I've created a lot of these types of formula/VBA combo reports for so non-tech type coworkers and most have a SOP page and a VBA "Magic Button" to prevent any user driven errors.

  5. #5
    Registered User
    Join Date
    05-10-2012
    Location
    USA
    MS-Off Ver
    Excel 365
    Posts
    41

    Re: Using Excel 2010 with multiple "if" & need all results in one cell, can't use textjoin

    Thanks Marv! I'll take a look at this.

  6. #6
    Forum Expert JBeaucaire's Avatar
    Join Date
    03-21-2004
    Location
    Bakersfield, CA
    MS-Off Ver
    2010, 2016, Office 365
    Posts
    33,492

    Re: Using Excel 2010 with multiple "if" & need all results in one cell, can't use textjoin

    Here's the custom function I offered, comments added to explain as we go:
    Please Login or Register  to view this content.
    I've installed it into your workbook. The formula is used in a cell as:

    =SPECIALIFS(TableData,WorkOrder,Component,DateCell)
    =SPECIALIFS(MRP!$A$1:$J$7,A2,C2,J2)

    Have a look.
    Attached Files Attached Files

  7. #7
    Registered User
    Join Date
    05-10-2012
    Location
    USA
    MS-Off Ver
    Excel 365
    Posts
    41

    Re: Using Excel 2010 with multiple "if" & need all results in one cell, can't use textjoin

    Wow Jerry! That is awesome. Clearly I have a lot to learn.

    Thanks for the help and education!

+ 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] Excel 2010 -- "Visual Basic" "Macros" and "Record Macro" all disabled.
    By NicholasL in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 05-07-2017, 06:11 AM
  2. Excel 2010 - Return date (MMM) from "multiple cells" otherwise blank
    By acopa00 in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 04-23-2014, 10:52 AM
  3. Replies: 10
    Last Post: 11-22-2013, 04:58 AM
  4. Excel 2010 (Run-time error '13' type mismatch) "Debug" and "Continue" Grayed out.
    By Jeronimo in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 12-18-2012, 06:42 PM
  5. Change "Parent" cell based on results of multiple "Children" cells
    By ccowman in forum Excel Formulas & Functions
    Replies: 16
    Last Post: 12-14-2012, 02:33 AM
  6. vba Excel 2010, "copy" RGB colour values from cell into variables
    By Efes in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 02-02-2012, 05:12 AM
  7. Using "Find" to return results if a word is found within multiple words in a cell
    By pylauzier in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 08-01-2011, 01:37 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