Thread: Three Variables
View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Biff Biff is offline
external usenet poster
 
Posts: 1,688
Default Three Variables

=SUMPRODUCT(--(A1:A100=variable_1),--(B1:B100=variable_2),--(C1:C100=variable_3))

TEXT variables need to be enclosed in double quotes " ": "Dr. x"
NUMBER variables SHOULD NOT be enclosed in quotes.

It's easier and more versatile to just use cells to hold the variables and
then refer to those cells:

D1 = Dr. x
E1 = THR
F1 = Unit 1

=SUMPRODUCT(--(A1:A100=D1),--(B1:B100=E1),--(C1:C100=F1))

Biff

"George" wrote in message
...
I have one database that tracks four procedures done at 40 locations by 12
doctors. I want to create a spreadsheet that will count the number of
occurences taking placing of the procedures by location by doctor. In
other
words Dr x performed 4 THR at Unit 10 and 3 THR at Unit 5, Dr Y performed
3
THR at Unit 1 and 3 THR at Unit 1. Any ideas on creating a three variable
spreadsheet?