Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
I'm having some trouble. I'd like to compare two columns and return data
from a third column when True. For example: Compare column A to Column C - Rows 1-1000. If A1 appears anywhere in C1-1000 i want to return the "text" in column D. The row in D is = to the true value in C. i.e. If A1=C47 I want to return the text in D47. Then repeat this for A2-A1000. Thanks |
#2
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
Something along these lines, I think - put this formula in D1:
=IF(COUNTIF(A$1:A$1000,C1)0,C1,"no match") and copy down. This is taking the approach: "if C1 appears anywhere in A1:A1000, then put C1 into D1" which I think is logically equivalent to what you said. Hope this helps. Pete On Nov 22, 8:15 pm, casedk wrote: I'm having some trouble. I'd like to compare two columns and return data from a third column when True. For example: Compare column A to Column C - Rows 1-1000. If A1 appears anywhere in C1-1000 i want to return the "text" in column D. The row in D is = to the true value in C. i.e. If A1=C47 I want to return the text in D47. Then repeat this for A2-A1000. Thanks |
#3
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
Pete,
Thanks! The countif took care of my issue with not counting the entire range! However, I still have the issue with the True statement. If my countif is true C1 appears somewhere between A1-A1000 I need to know where that "true" value was in A1-A1000. Was it A1 or A246 or A934 .... If C1 appears in A246 then I'd like to put D246 in as my true statement. In my problem A and D are related: A=id number B=description (text) C=random range of id numbers that I need the description (D). I want to see if C 1 appears anywhere in A 1-1000 (which your formula does). Once I find a place where C1=Ax I want to take that description Dx and place it in E1. So, I think I may need a second formula or need to modify the true statement. Thanks for you help. "Pete_UK" wrote: Something along these lines, I think - put this formula in D1: =IF(COUNTIF(A$1:A$1000,C1)0,C1,"no match") and copy down. This is taking the approach: "if C1 appears anywhere in A1:A1000, then put C1 into D1" which I think is logically equivalent to what you said. Hope this helps. Pete On Nov 22, 8:15 pm, casedk wrote: I'm having some trouble. I'd like to compare two columns and return data from a third column when True. For example: Compare column A to Column C - Rows 1-1000. If A1 appears anywhere in C1-1000 i want to return the "text" in column D. The row in D is = to the true value in C. i.e. If A1=C47 I want to return the text in D47. Then repeat this for A2-A1000. Thanks |
#4
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
You've changed the wording round now from what you originally put. Try
it this way round: =IF(COUNTIF(C$1:C$1000,A1)0,A1,"no match") if column A contains the important "text". Hope this helps. Pete On Nov 22, 11:43 pm, casedk wrote: Pete, Thanks! The countif took care of my issue with not counting the entire range! However, I still have the issue with the True statement. If my countif is true C1 appears somewhere between A1-A1000 I need to know where that "true" value was in A1-A1000. Was it A1 or A246 or A934 .... If C1 appears in A246 then I'd like to put D246 in as my true statement. In my problem A and D are related: A=id number B=description (text) C=random range of id numbers that I need the description (D). I want to see if C 1 appears anywhere in A 1-1000 (which your formula does). Once I find a place where C1=Ax I want to take that description Dx and place it in E1. So, I think I may need a second formula or need to modify the true statement. Thanks for you help. "Pete_UK" wrote: Something along these lines, I think - put this formula in D1: =IF(COUNTIF(A$1:A$1000,C1)0,C1,"no match") and copy down. This is taking the approach: "if C1 appears anywhere in A1:A1000, then put C1 into D1" which I think is logically equivalent to what you said. Hope this helps. Pete On Nov 22, 8:15 pm, casedk wrote: I'm having some trouble. I'd like to compare two columns and return data from a third column when True. For example: Compare column A to Column C - Rows 1-1000. If A1 appears anywhere in C1-1000 i want to return the "text" in column D. The row in D is = to the true value in C. i.e. If A1=C47 I want to return the text in D47. Then repeat this for A2-A1000. Thanks- Hide quoted text - - Show quoted text - |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Comparing two combos/cells to return a value | Excel Worksheet Functions | |||
comparing cell to row, return all matchs | Excel Worksheet Functions | |||
Comparing two columns of information with 2 new columns of informa | Excel Discussion (Misc queries) | |||
sumproduct return value by comparing two criteria..... | Excel Worksheet Functions | |||
Comparing two lists and return specified data | Excel Worksheet Functions |