Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我有这张表,我想创建一个公式,该公式将根据 columnA 和column的真实条件计算值C。
A
C
示例:如果在列中的A值为 M(男性),并且在列C中为 YES,则它会计数。
谁能帮我这个公式?
在单元格前面添加工作表名称,例如:
=COUNTIFS(stock!A:A,"M",stock!C:C,"Yes")
假设工作表名称为“stock”
如果您的数据在A1:C100当时:
A1:C100
Excel - 所有版本
=SUMPRODUCT(--(A1:A100="M"),--(C1:C100="Yes"))
Excel - 2007 年以后
=COUNTIFS(A1:A100,"M",C1:C100,"Yes")