Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TugboatEng on being selected by the Eng-Tips community for having the most helpful posts in the forums last week. Way to Go!

Counting rows in databse according to two columns of data

Status
Not open for further replies.

dewdog

Chemical
Joined
Jul 14, 2006
Messages
1
Location
US
We use excel spreadsheets as login databases for samples in the lab. Each row is a new sample with 10 or 12 columns of information. What I would like excel to do is to count the number of rows that were entered each month as well as if another column has an X or not. I am using two ifcounts, subtracted from each other to get the number of samples per month already. But everything I try to get excel to see if there is an X in another column backfires. Any help would be greatly appreciated.

dewdog
 
Look into COUNTA and DCOUNTA functions.

Cheers,
Joerd

Please see FAQ731-376 for tips on how to make the best use of Eng-Tips.
 
Hello,

SUMPRODUCT maybe the way to go, not knowing the layout of the data, have come up with the following example.

Col A has dates
Col B has x's.

In E1 enter an number for the month e.g. 2
In F1 enter x

Then in G1 enter the following formula

=SUMPRODUCT(--(MONTH($A$1:$A$6)=E1),--($B$1:$B$6=F1))


amend ranges as required.

----------------------------------
Hope this helps.
----------------------------------

maybe only a drafter
but the best user at this company!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top