+ Reply to Thread
Results 1 to 3 of 3

retrieve row of data only when a certain word is in a particular cell in that row

  1. #1
    Registered User
    Join Date
    12-01-2011
    Location
    Birmingham
    MS-Off Ver
    Excel 2010
    Posts
    15

    retrieve row of data only when a certain word is in a particular cell in that row

    Hi All,

    I have a query that my level of Excel knowledge is preventing me from solving. Was hoping that someone could help :-)

    I have an excel file with a great deal of data from sites all around the world. What I would like to do is take data from this file but only for a specific site and have it automatically appear in a new workbook every time that site name appears.

    In the example attached the supplier column (C) is the column that contains the list of sites from which i want to take the data from, but only when the cell in column C contains 'not'. if this is true, then i would like to take the whole of that row and put it into a new line in a new workbook. . . if that makes sense.

    Any help would be appreciated! I have been exploring with =SUMIF. . . would that be a way of doing it?

    thanks in advanceExample.xlsx
    Last edited by smilking; 01-13-2012 at 09:59 AM.

  2. #2
    Forum Expert NBVC's Avatar
    Join Date
    12-06-2006
    Location
    Mississauga, CANADA
    MS-Off Ver
    2003:2010
    Posts
    34,898

    Re: retrieve row of data only when a certain word is in a particular cell in that row

    In O2 of sheet 1 add a helper column to count matches:

    =IF(C2="not",COUNT(O$1:O1)+1,"")

    copied down

    in P2 get total count:

    =MAX(O:O)

    Then in Sheet2, A2:

    =IF(ROWS($A$2:$A2)>Sheet1!$P$2,"",INDEX(Sheet1!A:A,MATCH(ROWS($A$2:$A2),Sheet1!$O:$O)))

    copied down and across as far as you need.

    Column A will need to formatted as Date.
    Attached Files Attached Files
    Where there is a will there are many ways.

    If you are happy with the results, please add to the contributor's reputation by clicking the reputation icon (star icon) below left corner

    Please also mark the thread as Solved once it is solved. Check the FAQ's to see how.

  3. #3
    Registered User
    Join Date
    12-01-2011
    Location
    Birmingham
    MS-Off Ver
    Excel 2010
    Posts
    15

    Re: retrieve row of data only when a certain word is in a particular cell in that row

    Hi NBVC,

    Thank you for that incredibly quick reply!

    What you have outlined works like a treat. . . thank you ever so much.

+ 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