Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 2,836
Default Match Values in Rows with Partial Values in Columns

I am trying to match values such as A, B, C, and D, all in rows, with
corresponding values, all in columns. The columns looks like the following:
A A B B B C A B C A C C C D A C D A B C
D...you get the idea. There are 15 columns of combinations of A, B, C, and D.

I am trying to place a 1 in the cell where the value in the columns match
the values in the rows and a 0 where there are no matches. For instance,
in the cell that references both A and A, I would like to have a "1". In a
cell that references both A and A B, I would like to have a "1", which tells
me there is at least a partial match. If I reference a cell with both B and
A B, I would like to have a "1" (again, there is a partial match here).

Im sure it requires some kind of IF function. It may require a CSE
function. I tried combinations of VLOOKUP and SUMPRODUCT and MATCH; didnt
achieve desired results yet.

Has anyone here dealt with this kind of issue before?

Cordially,
Ryan---

  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Max Max is offline
external usenet poster
 
Posts: 9,221
Default Match Values in Rows with Partial Values in Columns

Assume lookup values in A2 down, col headers in B1 across

Put in B2:
= --ISNUMBER(SEARCH($A2,B$1))
Copy across/fill down to populate the grid

Replace SEARCH with FIND if you need it to be a stricter case sensitive
search. SEARCH is not case sensitive.
--
Max
Singapore
http://savefile.com/projects/236895
xdemechanik
---
"ryguy7272" wrote:
I am trying to match values such as A, B, C, and D, all in rows, with
corresponding values, all in columns. The columns looks like the following:
A A B B B C A B C A C C C D A C D A B C
D...you get the idea. There are 15 columns of combinations of A, B, C, and D.

I am trying to place a 1 in the cell where the value in the columns match
the values in the rows and a 0 where there are no matches. For instance,
in the cell that references both A and A, I would like to have a "1". In a
cell that references both A and A B, I would like to have a "1", which tells
me there is at least a partial match. If I reference a cell with both B and
A B, I would like to have a "1" (again, there is a partial match here).

Im sure it requires some kind of IF function. It may require a CSE
function. I tried combinations of VLOOKUP and SUMPRODUCT and MATCH; didnt
achieve desired results yet.

Has anyone here dealt with this kind of issue before?

Cordially,
Ryan---

  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 1,231
Default Match Values in Rows with Partial Values in Columns

"Max" wrote...
....
Put in B2:
= --ISNUMBER(SEARCH($A2,B$1))

....

Save some keystrokes.

=COUNT(SEARCH($A2,B$1))


  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 2,836
Default Match Values in Rows with Partial Values in Columns

Wow! You guys are amazing! Both functions worked excellent. I noticed that
blanks resulted in 1s, so I modified Harlans function and went with the
following: =IF($A2="",0,COUNT(SEARCH($A2,B$1)))

Thanks so much guys!!
Ryan---



"Harlan Grove" wrote:

"Max" wrote...
....
Put in B2:
= --ISNUMBER(SEARCH($A2,B$1))

....

Save some keystrokes.

=COUNT(SEARCH($A2,B$1))



Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Copy values in columns to rows Carpe Diem Excel Worksheet Functions 0 December 20th 06 09:01 PM
match values in two different columns thomasNg Excel Worksheet Functions 2 November 24th 05 02:38 AM
How do I match identical values in 2 columns and then sort? Godswatch Excel Discussion (Misc queries) 1 November 9th 05 06:55 PM
How do I lookup values from rows and columns Simultaneously PK Excel Worksheet Functions 2 March 29th 05 04:34 PM
Match values from two columns pek Excel Worksheet Functions 1 November 30th 04 03:18 PM


All times are GMT +1. The time now is 06:36 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright 2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"