+ Reply to Thread
Results 1 to 8 of 8

Formula needed to return data over a series of columns

  1. #1
    Registered User
    Join Date
    11-17-2017
    Location
    Portsmouth
    MS-Off Ver
    10
    Posts
    3

    Formula needed to return data over a series of columns

    i have a report that has branch information somewhere across columns D2:I2 (the branch info was not allocated to a particular column) - what i need is a formula that will look across the columns to find the name of the "branch:**" then return information about that branch located on another sheet.

    i have tried IF and VLOOKUPS and i can't get anything to work. i have looked at MATCH

    IF branch:London then return branch:London,region=Homeworking,area=Homeworking

    i have made sure that the return data is in one column - but wonder if the trouble i am having is because the branch data could be anywhere in the columns.

    i have over 300 branches and don't want to add their names to the forumla and over 4000 lines of data to match.
    Attached Files Attached Files
    Last edited by dixiedimmock; 11-17-2017 at 10:01 AM. Reason: solved

  2. #2
    Forum Expert leelnich's Avatar
    Join Date
    03-20-2017
    Location
    Delaware, USA
    MS-Off Ver
    Office 2016
    Posts
    2,807

    Re: Formula needed to return data over a series of columns

    Hi, Dixie, welcome to Excel Forum! A small sample workbook (NOT a picture) would really help us to solve your problem quickly and accurately.
    Please remove any sensitive or extraneous info.
    Try to preserve the original layout so our solutions fit your workbook.
    Provide “realistic” data. Include any variations the code or formula must address.
    If appropriate, perhaps simulate some results to demonstrate what you want.

    To attach a workbook:
    Click Edit Post (or just start a new reply.)
    Click Go Advanced
    Scroll down to Manage Attachments and click.
    Now click Browse, find your file, then click Upload. Simple!
    Clicking the Add Reputation star below helpful posts is a great way to show your appreciation.
    Please mark your threads as SOLVED upon conclusion (Thread Tools above Post # 1). - Lee

  3. #3
    Forum Expert
    Join Date
    11-22-2016
    Location
    Cornwall,UK
    MS-Off Ver
    office 365
    Posts
    4,240

    Re: Formula needed to return data over a series of columns

    This assumes that you are looking for the first cell with a value in one of the columns D:I

    Try this to get your lookup value to feed into the lookup formula
    Formula: copy to clipboard
    Please Login or Register  to view this content.


    Here is formula with lookup aimed at another sheet in same workbook
    Formula: copy to clipboard
    Please Login or Register  to view this content.


    And modified to lookup another workbook
    Formula: copy to clipboard
    Please Login or Register  to view this content.


    The link to another file will not work in the attached, and columnL formula will require modifying.
    Attached Files Attached Files
    Last edited by kev_; 11-17-2017 at 08:04 AM.
    Click *Add Reputation to thank those who helped you. Ask if anything is not clear

  4. #4
    Forum Expert leelnich's Avatar
    Join Date
    03-20-2017
    Location
    Delaware, USA
    MS-Off Ver
    Office 2016
    Posts
    2,807

    Re: Formula needed to return data over a series of columns

    This, if you need to find the cell containing "branch*":
    Please Login or Register  to view this content.

  5. #5
    Registered User
    Join Date
    11-17-2017
    Location
    Portsmouth
    MS-Off Ver
    10
    Posts
    3

    Re: Formula needed to return data over a series of columns

    Hi

    i have tried both sets of answers and it returns the value in the D column - i have uploaded a dummy spread with the information.

    not sure what i am doing wrong as the value could be in any column between D-I.

  6. #6
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    44,064

    Re: Formula needed to return data over a series of columns

    1. there are extraneous spaces before all of the text in cols D-I. A bit of a pain, but this formula deals with that.

    2. Portsmouth is spelled incorrectly in sheet2.

    3. Your expected answer for London was incorrect.

    =IFERROR(INDEX(Sheet2!$A$2:$A$4,MATCH("*"&INDEX(Sheet2!$A$2:$A$4,MATCH("*"&TRIM(INDEX(A2:H2,MATCH("*branch:*",A2:H2,0)))&"*",Sheet2!$A$2:$A$4,0))&"*",Sheet2!$A$2:$A$4,0)),"")
    Attached Files Attached Files
    Glenn




    None of us get paid for helping you... we do this for fun. So DON'T FORGET to say "Thank You" to all who have freely given some of their time to help YOU.

    Temporary addition of accented to illustrate ongoing problem to the TT: Lá fhéile Pádraig sona dhaoibh

  7. #7
    Registered User
    Join Date
    11-17-2017
    Location
    Portsmouth
    MS-Off Ver
    10
    Posts
    3

    Re: Formula needed to return data over a series of columns

    thank you! it was test data so not completely accurate - it has worked! thank you so much.

  8. #8
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    44,064

    Re: Formula needed to return data over a series of columns

    You're welcome.



    If that takes care of your original question, please select "Thread Tools" from the menu link above and mark this thread as SOLVED.

    It'd also be appreciated if you were to click the Add Reputation button at the foot of any of the posts of all members who helped you reach a solution.

+ 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. Formula Needed To Count Columns With Data
    By taskmann in forum Excel Formulas & Functions
    Replies: 13
    Last Post: 07-19-2016, 01:21 PM
  2. [SOLVED] Formula needed to match two columns on two spreadsheets and return a third
    By scyllanbay in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 03-14-2014, 11:26 AM
  3. return 100% or 0% if criteria is met in a series of columns
    By photosko in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 07-17-2013, 02:34 PM
  4. [SOLVED] How to return the lowest value of a series of columns when matching a record
    By Ozzy24 in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 05-10-2013, 01:36 AM
  5. Formula Needed to Match and Return Data from a Different Sheet
    By gunk in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 09-25-2012, 08:35 PM
  6. [SOLVED] Which formula would work for this series? ..Help needed
    By ssciarrino in forum Excel General
    Replies: 4
    Last Post: 01-31-2006, 11:20 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