Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 4
Default Counting date and catagory match

I want excel to return a number if there is a date match in column B and a
Category Name match in column C. I want to be able to do it for the whole
column because the amount of items that occur on certain dates tend to
fluctuates.
  #2   Report Post  
Posted to microsoft.public.excel.misc
JMB JMB is offline
external usenet poster
 
Posts: 2,062
Default Counting date and catagory match

to return something from column D, for example
=INDEX(D1:D100, MATCH(1, (B1:B100=SomeDate)*(C1:C100=SomeCategory), 0))

entered w/ Ctrl+Shift+Enter. if done properly, XL will put braces { }
around the formula.


"Reed" wrote:

I want excel to return a number if there is a date match in column B and a
Category Name match in column C. I want to be able to do it for the whole
column because the amount of items that occur on certain dates tend to
fluctuates.

  #3   Report Post  
Posted to microsoft.public.excel.misc
JMB JMB is offline
external usenet poster
 
Posts: 2,062
Default Counting date and catagory match

looking at your subject header, do you want to count how many items match a
particular date and category??

=SUMPRODUCT(--(B1:B100=SomeDate), --(C1:C100=SomeCategory))



"JMB" wrote:

to return something from column D, for example
=INDEX(D1:D100, MATCH(1, (B1:B100=SomeDate)*(C1:C100=SomeCategory), 0))

entered w/ Ctrl+Shift+Enter. if done properly, XL will put braces { }
around the formula.


"Reed" wrote:

I want excel to return a number if there is a date match in column B and a
Category Name match in column C. I want to be able to do it for the whole
column because the amount of items that occur on certain dates tend to
fluctuates.

  #4   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 4
Default Counting date and catagory match

Hello,

Yes thats correct, like B will be 11/1/07 a few times, then 11/7/07 and so
on, then C will be the name of a certain category. I just want to be able to
do this for the whole of B not just a little section of it because the number
of 11/07s may change as the month goes on

"JMB" wrote:

looking at your subject header, do you want to count how many items match a
particular date and category??

=SUMPRODUCT(--(B1:B100=SomeDate), --(C1:C100=SomeCategory))



"JMB" wrote:

to return something from column D, for example
=INDEX(D1:D100, MATCH(1, (B1:B100=SomeDate)*(C1:C100=SomeCategory), 0))

entered w/ Ctrl+Shift+Enter. if done properly, XL will put braces { }
around the formula.


"Reed" wrote:

I want excel to return a number if there is a date match in column B and a
Category Name match in column C. I want to be able to do it for the whole
column because the amount of items that occur on certain dates tend to
fluctuates.

  #5   Report Post  
Posted to microsoft.public.excel.misc
JMB JMB is offline
external usenet poster
 
Posts: 2,062
Default Counting date and catagory match

you could adjust the ranges to suit your needs
=SUMPRODUCT(--(B1:B65535=SomeDate), --(C1:C65535=SomeCategory))

Prior to XL 2007, sumproduct cannot work on entire columns (so B:B and
B1:B65536 will not work).

"Reed" wrote:

Hello,

Yes thats correct, like B will be 11/1/07 a few times, then 11/7/07 and so
on, then C will be the name of a certain category. I just want to be able to
do this for the whole of B not just a little section of it because the number
of 11/07s may change as the month goes on

"JMB" wrote:

looking at your subject header, do you want to count how many items match a
particular date and category??

=SUMPRODUCT(--(B1:B100=SomeDate), --(C1:C100=SomeCategory))



"JMB" wrote:

to return something from column D, for example
=INDEX(D1:D100, MATCH(1, (B1:B100=SomeDate)*(C1:C100=SomeCategory), 0))

entered w/ Ctrl+Shift+Enter. if done properly, XL will put braces { }
around the formula.


"Reed" wrote:

I want excel to return a number if there is a date match in column B and a
Category Name match in column C. I want to be able to do it for the whole
column because the amount of items that occur on certain dates tend to
fluctuates.



  #6   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 4
Default Counting date and catagory match

So like? =SUMPRODUCT((B1:B100=11/1/2007), (C1:C100=Referral))

this report an error

"JMB" wrote:

you could adjust the ranges to suit your needs
=SUMPRODUCT(--(B1:B65535=SomeDate), --(C1:C65535=SomeCategory))

Prior to XL 2007, sumproduct cannot work on entire columns (so B:B and
B1:B65536 will not work).

"Reed" wrote:

Hello,

Yes thats correct, like B will be 11/1/07 a few times, then 11/7/07 and so
on, then C will be the name of a certain category. I just want to be able to
do this for the whole of B not just a little section of it because the number
of 11/07s may change as the month goes on

"JMB" wrote:

looking at your subject header, do you want to count how many items match a
particular date and category??

=SUMPRODUCT(--(B1:B100=SomeDate), --(C1:C100=SomeCategory))



"JMB" wrote:

to return something from column D, for example
=INDEX(D1:D100, MATCH(1, (B1:B100=SomeDate)*(C1:C100=SomeCategory), 0))

entered w/ Ctrl+Shift+Enter. if done properly, XL will put braces { }
around the formula.


"Reed" wrote:

I want excel to return a number if there is a date match in column B and a
Category Name match in column C. I want to be able to do it for the whole
column because the amount of items that occur on certain dates tend to
fluctuates.

  #7   Report Post  
Posted to microsoft.public.excel.misc
JMB JMB is offline
external usenet poster
 
Posts: 2,062
Default Counting date and catagory match

Couple of issues:
First - you omitted the double unary operator -- (it's use is explained in
the link below)
Second - XL treats 11/1/2007 as 11 divided by 1 divided by 2007 when entered
in this manner. XL stores dates as numbers. 11/1/2007 is the result of a
format that is applied to the number so it makes sense to us humans.
Third - is referral a named range? If not and you are searching for the
word referral, it needs to be in quotes.

I expect this should work:
=SUMPRODUCT(--(B1:B100=DATE(2007, 11, 1)), --(C1:C100="Referral"))

or use cell references for the desired date and category
=SUMPRODUCT(--(B1:B100=D1)), --(C1:C100=E1))

more on using sumproduct for multiple condition tests he
http://xldynamic.com/source/xld.SUMPRODUCT.html


"Reed" wrote:

So like? =SUMPRODUCT((B1:B100=11/1/2007), (C1:C100=Referral))

this report an error

"JMB" wrote:

you could adjust the ranges to suit your needs
=SUMPRODUCT(--(B1:B65535=SomeDate), --(C1:C65535=SomeCategory))

Prior to XL 2007, sumproduct cannot work on entire columns (so B:B and
B1:B65536 will not work).

"Reed" wrote:

Hello,

Yes thats correct, like B will be 11/1/07 a few times, then 11/7/07 and so
on, then C will be the name of a certain category. I just want to be able to
do this for the whole of B not just a little section of it because the number
of 11/07s may change as the month goes on

"JMB" wrote:

looking at your subject header, do you want to count how many items match a
particular date and category??

=SUMPRODUCT(--(B1:B100=SomeDate), --(C1:C100=SomeCategory))



"JMB" wrote:

to return something from column D, for example
=INDEX(D1:D100, MATCH(1, (B1:B100=SomeDate)*(C1:C100=SomeCategory), 0))

entered w/ Ctrl+Shift+Enter. if done properly, XL will put braces { }
around the formula.


"Reed" wrote:

I want excel to return a number if there is a date match in column B and a
Category Name match in column C. I want to be able to do it for the whole
column because the amount of items that occur on certain dates tend to
fluctuates.

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
Counting when both match Greg D Excel Worksheet Functions 3 May 8th 06 05:22 PM
Catagory Axis tgorham Charts and Charting in Excel 1 November 7th 05 08:15 PM
I AM TRYING TO ADD INFO TO THE CATAGORY AXIS BUT IT WONT LET ME C. CINDY Charts and Charting in Excel 2 March 23rd 05 08:18 PM
How do I change the scale of the catagory axis? amcmaster Charts and Charting in Excel 1 March 2nd 05 04:46 PM
Formatting a cell as "text" in the number catagory. Ed Excel Worksheet Functions 3 December 7th 04 07:12 PM


All times are GMT +1. The time now is 07:25 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"