View Single Post
  #8   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Glenn Glenn is offline
external usenet poster
 
Posts: 1,240
Default Excel, two text fields equal the number 1 per occurance

Describes exactly what you want to do. How does that not help?

Don McLean wrote:
Doesn't help, any other ideas?

"Glenn" wrote:

http://www.contextures.com/xlFunctio...tml#SumProduct

Don McLean wrote:
I basically need the
=countif(range, "text") function that is conditional on whether or not
another column has specific text.

Thanks. ~Don

"Jacob Skaria" wrote:

Assume the data range is A1:B100 with headers in Row1.

With the query name in C2 and item in D2 try the below formula

=SUMPRODUCT(--(A2:A100=C2),--(B2:B100=D2))
--
If this post helps click Yes
---------------
Jacob Skaria


"Don McLean" wrote:

I am in need of help with an excel function. Here is some sample data.

Don coffee
James coffee
Joe tea
Sally coffee
Don tea
Sally tea
Sally tea
Don coffee

I need these two columns to be conditional in that If Don drinks tea that
equals one occurance. The data I need would show that Don drinks tea "1", Don
drinks coffee "2". Sally drinks tea "2", Sally drinks coffee "1".

Can anyone please help me? Thanks.