+ Reply to Thread
Results 1 to 4 of 4

Need to reference the value of a third column when searching a range for a specific value

  1. #1
    Registered User
    Join Date
    03-04-2013
    Location
    United States
    MS-Off Ver
    Excel 2003
    Posts
    4

    Need to reference the value of a third column when searching a range for a specific value

    I have a large amount of data (50,000 rows or so), and for the sake of my question there are 3 relevant columns; column A that contains a program number, column B that contains a task number (there are many tasks that will have the same program number), and column C that contains task numbers that have met a series of other requirements (all these task numbers exist in column B). I'm trying to write a function that when i search column B with a specific value from column C, it will give me the value of column A where column B is equal to that value from column C.
    Example:

    Column A...........Column B............Column C
    Program#....... Task#..............Important task#.........Output that i want
    1...................... A ......................... B................................1
    1...................... B ......................... E................................2
    1......................C .........................H..................................3
    2......................D .........................J ..................................3
    2...................... E .........................M................................ 4
    2......................F
    2...................... G
    3...................... H
    3...................... I
    3...................... J
    4...................... K
    4...................... L
    4...................... M

    I understand the concepts of writing functions and I've tried tinkering with making an IF function work, but I don't have a big enough knowledge base of them and I just can't seem to figure out how to make this work or if it's even possible. I'm open to any sort of solution that will accomplish the end goal. Thanks!
    Last edited by carterbu; 10-17-2013 at 10:53 AM.

  2. #2
    Forum Guru benishiryo's Avatar
    Join Date
    03-25-2011
    Location
    Singapore
    MS-Off Ver
    Excel 2013
    Posts
    5,147

    Re: Need to reference the value of a third column when searching a range for a specific v

    welcome to the forum, carterbu. maybe:
    =INDEX(A:A,MATCH(C2,B:B,0))

    if it doesn't work, I suggest you upload an Excel file in the thread. To do that, Click on GO ADVANCED and use the paperclip icon to open the upload window.
    View Pic
    and to illustrate your example better, click on How To Get Quick & Good Answers

    Thanks, if you have clicked on the * and added our rep.

    If you're satisfied with the answer, click Thread Tools above your first post, select "Mark your thread as Solved".

    "Contentment is not the fulfillment of what you want, but the realization of what you already have."


    Tips & Tutorials I Compiled | How to Get Quick & Good Answers

  3. #3
    Registered User
    Join Date
    03-04-2013
    Location
    United States
    MS-Off Ver
    Excel 2003
    Posts
    4

    Re: Need to reference the value of a third column when searching a range for a specific v

    Thanks Ben, that actually worked just how i needed it to. That makes a lot of sense seeing it now and i can modify and use that with confidence. Hahaha, like i said i understand how functions work, i just dont know them well enough off hand to write them from scratch. Looks like i've got some more learning to do. Thanks again.

  4. #4
    Forum Contributor arlu1201's Avatar
    Join Date
    09-09-2011
    Location
    Bangalore, India
    MS-Off Ver
    Excel 2003 & 2007
    Posts
    19,166

    Re: Need to reference the value of a third column when searching a range for a specific v

    Based on your last post in this thread, its apparent that you are satisfied with the solution(s) you've received and have solved your question, but you haven't marked your thread as "SOLVED". I will do it for you this time.

    In future, to mark your thread as Solved, you can do the following -
    Select Thread Tools-> Mark thread as Solved.

    Incase your issue is not solved, you can undo it as follows -
    Select Thread Tools-> Mark thread as Unsolved.

    Also, since you are relatively new to the forum, i would like to inform you that you can thank those who have helped you by clicking the small star icon located in the lower left corner of the post which helped you. This adds to the reputation of the person who has taken the time to help you.
    If I have helped, Don't forget to add to my reputation (click on the star below the post)
    Don't forget to mark threads as "Solved" (Thread Tools->Mark thread as Solved)
    Use code tags when posting your VBA code: [code] Your code here [/code]

+ 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. Searching cells within a range that contain specific text
    By JohnG73 in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 09-20-2016, 05:52 AM
  2. [SOLVED] Searching for first reference in column
    By gmtaiv in forum Excel Formulas & Functions
    Replies: 7
    Last Post: 07-01-2013, 02:14 AM
  3. Searching Column and returning specific rows to UserForm
    By battdan1 in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 06-26-2013, 06:54 PM
  4. [SOLVED] Cond. formatting a column/Range, highlight cell in column/range if equal to specific text
    By DFrank231 in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 03-19-2013, 03:35 PM
  5. Replies: 2
    Last Post: 09-11-2012, 12:07 AM

Tags for this Thread

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