如何使用countifs计数多个列 [英] how to count multiple columns using countifs

查看:767
本文介绍了如何使用countifs计数多个列的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用一个公式来计算报价的次数在给定列中的字母 Q 表示,当我将公式放在一个列我得到正确的答案,但是当我想做多列,我得到零,任何人可以帮助吗?
公式是

  = COUNTIFS(D10:D29,= Q,G10:G29,= Q )


解决方案

尝试



= SUMPRODUCT((D10:D29 =Q)+(G10:G29 =Q))





= SUMPRODUCT(((D10:D29 =Q)+(G10:G29 = Q)> 0)+0)



如果您在D10和G10中都有Q,则前者将计数2即使有两个Q


,每个行最多只能算一次

I am putting in a formula to count the number of times a quote is required Indicated by the letter Q in a given column, when I put the formula in for one column I get the correct answer, but when I want to do it for multiple columns I get zero, can anyone help please? the formula is

=COUNTIFS(D10:D29,"=Q",G10:G29,"=Q")

解决方案

Try either

=SUMPRODUCT((D10:D29="Q")+(G10:G29="Q"))

or

=SUMPRODUCT(((D10:D29="Q")+(G10:G29="Q")>0)+0)

the former will count 2 if you have Qs in both D10 and G10 - the latter only counts each row once at most, even if there are two "Q"s

这篇关于如何使用countifs计数多个列的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆