两列中两个日期之间的和 [英] Sumif between two dates over two columns

查看:94
本文介绍了两列中两个日期之间的和的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想对两个日期之间的一列求和,但是这些日期在不同的列中。

I would like to sum a column between two dates, however the dates are in separate columns.

我想要以下日期01-01-2014(单元格E1)和31-03-2014(单元格F1)之间的总和。

I want the sum total between the following dates 01-01-2014 (cell E1) and 31-03-2014 (cell F1).

如果您查看单元格C6,则该日期低于第一个范围,并且包含的​​日期与您期望的一样。

If you look at cell C6 the date is lower than the first range and is being included as you would expect.

当前公式分别查看两列,即E1上方的开始日期(B列),然后F1下方的结束日期(C列)。

The current formula looks at the two columns individually i.e. is Start date (column B) above E1 and then is End date (column C) below F1.

我需要一个考虑两个日期的公式,即,如果开始日期在E1以上且在F1以下,则对价格列求和。

I need a formula that takes into account both dates i.e if start date is above E1 and below F1 then sum the Price column.

我想避免C6的日期,即使它在F1单元格下方,我仍然希望它在E1单元格上方。

The date at C6 is something I would like to avoid, even though it is below cell F1 I still want it to be above cell E1.

有人能在我的操作方法上提供帮助吗?

Is anyone able to lend some assistance on how I could do this?

推荐答案

请尝试:

=SUMIFS(E:E,B:B,">="&E1,C:C,">"&E1,C:C,"<="&F1)

这篇关于两列中两个日期之间的和的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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