+ Reply to Thread
Results 1 to 7 of 7

Presence of values within a column when observing two rows

  1. #1
    Registered User
    Join Date
    05-25-2012
    Location
    Cambridge
    MS-Off Ver
    Excel 2003
    Posts
    22

    Presence of values within a column when observing two rows

    Hi,

    I have the following data:

    Excel Data.JPG

    I have two rows for Jim (a&b) and two rows for Bill (a&b). Each value associated to each name is recorded as a letter (either a,b,c,d). What I would like to do is for rows 6 and 7 to recognise as to whether a particular column has a letter value against it combining Jim a and Jim b; repeating this for Bill a and Bill b. For example, for Jim: Column B both Jim a and b score, so I would like the cell (in this case B6) to recognise that fact, perhaps give it a 'P' present; Column C for Jim (C6) would be blank as no letter is present for Jim a&b, whilst both column D & E (D6 & E6) should return 'P' as Jim a has a letter present (despite Jim b not having a letter present).

    I apologise for long dogged explanation. But I hope someone can help.
    Last edited by drewsta; 12-08-2014 at 09:35 AM.

  2. #2
    Registered User
    Join Date
    09-07-2011
    Location
    London, UK
    MS-Off Ver
    Excel 2007
    Posts
    38

    Re: Presence of values within a column when observing two rows

    Hi Drewsta,

    Here is what I can suggest, let me know if it fits the purpose:

    Formula in cells B6 to E7 and further.

    =IF(SUMPRODUCT((--(ISNUMBER(SEARCH($A6,$A1:$A4)))),(--(B1:B4<>"")))>0,"P","")

    It looks for work Jim in row 6 and for Bill in row 7, and basically for any name the you have in column A, to the left of your formula.

    Then when it finds the name in the range above (A1:A4 in this example) [regardless of what the name is followed by - a letter or number or something else], it looks for what is in respective rows in the column of the formula, and if it is not empty, retunes a number (otherwise returns 0). If value is >0, returns 'P'.

    (--) is used to convert TRUE/FALSE returned by formula into numeric value - 1/0 respectively.

    Cheers,
    Michael

  3. #3
    Registered User
    Join Date
    05-25-2012
    Location
    Cambridge
    MS-Off Ver
    Excel 2003
    Posts
    22

    Re: Presence of values within a column when observing two rows

    Hi Michael,

    Many thanks for your quick response. That works great. Rather than restrict it searching particular cell ranges, how would I adapt the formula to look for associated combination of names and the numbers within those rows?

  4. #4
    Registered User
    Join Date
    09-07-2011
    Location
    London, UK
    MS-Off Ver
    Excel 2007
    Posts
    38

    Re: Presence of values within a column when observing two rows

    Could you please include a workbook with more specific example please?

  5. #5
    Registered User
    Join Date
    05-25-2012
    Location
    Cambridge
    MS-Off Ver
    Excel 2003
    Posts
    22

    Re: Presence of values within a column when observing two rows

    Hi Gutkinma,

    Please refer to my data picture in the #1 post. I would like Cell B6 to lookup the data range B1:B4 by searching column A and identifying the relevant rows named Jim a or Jim b to identify the relevant associated cells in column B.

  6. #6
    Registered User
    Join Date
    09-07-2011
    Location
    London, UK
    MS-Off Ver
    Excel 2007
    Posts
    38

    Re: Presence of values within a column when observing two rows

    Hi Drewsta,

    Please see attached workbook.

    Hopefully this does the trick.

    Thanks

    Book1.xls

  7. #7
    Registered User
    Join Date
    05-25-2012
    Location
    Cambridge
    MS-Off Ver
    Excel 2003
    Posts
    22

    Re: Presence of values within a column when observing two rows

    Is there a way of doing the same by combining searching for two different words. So if I wanted to carry out the same function but instead of having Jim a & Jim b I had Jim and Sarah how should the formula be constructed?

    Excel Data.JPG

+ 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] Looking Up Values in the Presence of Duplicates
    By andrewc in forum Excel General
    Replies: 3
    Last Post: 03-03-2014, 11:56 AM
  2. [SOLVED] Macro/VBA to Change Order of Rows/Add Rows based on specific text content presence/absence
    By cmaunder in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 07-07-2013, 04:50 PM
  3. [SOLVED] Formula to calculate sum of column range based on presence of value in another column
    By abreet in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 09-23-2012, 10:37 PM
  4. [SOLVED] Workday function for 7 day work week (only observing holidays)
    By Alann in forum Excel General
    Replies: 3
    Last Post: 05-09-2012, 12:58 PM
  5. Checking for the Presence of Specified Values within a Range
    By ExcelTip in forum Tips and Tutorials
    Replies: 0
    Last Post: 08-25-2005, 03:35 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