在Excel中,将每行中的一列中的所有值求和,其中另一列是特定值

编程入门 行业动态 更新时间:2024-10-27 10:34:30
本文介绍了在Excel中,将每行中的一列中的所有值求和,其中另一列是特定值的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述 我想知道是否有一个简单的方法来做我正在寻找的东西。基本上,我在Excel 2011中有一堆资料表。我一直想要看到的一个特定的信息是没有报销的数量。换句话说,我有一个支付金额的列,另一个是否已经报销(是/否)。我想把所有付款的金额都归结于所报酬的字段等于否。

我认识到我可以总结整个列,并将那些已经被报销,但我希望它显示全部的金额,无论过滤器是什么(或如果没有过滤器)。

我无法找到很好的关键字来形容这个Google,所以我在这里问。我想在Excel中完成,而不是外部程序或脚本。

解决方案

如果列A包含的数量报销,列B包含是/否,表示是否已报销,那么以下任何一项都可以正常运行,但建议使用第一个选项:

= SUMIF(B:B,否,A:A)

= SUMIFS(A:A,B:B,否)

这是一个示例,显示一小部分样本数据支付和未偿还的金额。

ABCD 报销金额?支付总额:= SUMIF(B:B,是,A:A) $ 100是总计未完成:= SUMIF(B:B,否,A:A) $ 200否 $ 300否 $ 400是 $ 500否

I'm wondering if there is an easy way to do what I'm looking for. Basically, I have a balance sheet in Excel 2011 with a bunch of data. One specific piece of information I always want visible is the amount that hasn't been reimbursed. In other words, I have a column for the amount paid and another for whether or not it has been reimbursed (Yes/No). I want to sum all of the amounts paid where the reimbursed field is equal to 'No'.

I recognize I can sum the entire column and filter out those that have been reimbursed, but I'd like it to display the full amount regardless of what filter is on (or if no filter is on).

I wasn't able to find good keywords to describe this to Google, so I'm asking here. I would like to accomplish this in Excel, not in an external program or script.

解决方案

If column A contains the amounts to be reimbursed, and column B contains the "yes/no" indicating of whether the reimbursement has been made, then either of the following will work, though the first option is recommended:

=SUMIF(B:B,"No",A:A)

or

=SUMIFS(A:A,B:B,"No")

Here is an example that will display the amounts paid and outstanding for a small set of sample data.

A B C D Amount Reimbursed? Total Paid: =SUMIF(B:B,"Yes",A:A) $100 Yes Total Outstanding: =SUMIF(B:B,"No",A:A) $200 No $300 No $400 Yes $500 No

更多推荐

在Excel中,将每行中的一列中的所有值求和,其中另一列是特定值

本文发布于:2023-10-30 08:13:44,感谢您对本站的认可!
本文链接:https://www.elefans.com/category/jswz/34/1542279.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:定值   Excel   列是特

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!