Warning: file_get_contents(/data/phpspider/zhask/data//catemap/5/excel/28.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
excel:如何确定日期是否在日期范围内_Excel - Fatal编程技术网

excel:如何确定日期是否在日期范围内

excel:如何确定日期是否在日期范围内,excel,Excel,我的Excel工作表中有以下数据: A1: dec. 25, 2017 A2: feb. 25, 2018 A3: jan. 27, 2018 A4: 1 A5: 2 A6: (this is where result should be) 我目前对A6的公式是: if(and(datevalue(text(A2,"mm/dd/yy")) >= datevalue(text(A1,"mm/dd/yy")), datevalue(text(A2,"mm/dd/yy")) <= dat

我的Excel工作表中有以下数据:

A1: dec. 25, 2017
A2: feb. 25, 2018
A3: jan. 27, 2018
A4: 1
A5: 2
A6: (this is where result should be)
我目前对A6的公式是:

if(and(datevalue(text(A2,"mm/dd/yy")) >= datevalue(text(A1,"mm/dd/yy")), datevalue(text(A2,"mm/dd/yy")) <= datevalue(text(A3,"mm/dd/yy"))), A4/A5, 0)

if(and(datevalue)(text(A2,“mm/dd/yy”)>=datevalue(text(A1,“mm/dd/yy”))、datevalue(text(A2,“mm/dd/yy”)))如果
A1:A3
正确地格式化为日期(time)值,操作它们应该不会那么困难。
=if(and(A2>=A1,A2)是与本问题中的格式完全相同的日期
=DATE(RIGHT(A1,4), MONTH(1&LEFT(A1,3)), MID(A1,6,2))