Excel min value greater than x returns 0 if no value found?

后端 未结 2 423
梦谈多话
梦谈多话 2021-01-15 10:29

I am using the following formula: =MIN(IF(A1:A5>B1,A1:A5)) use Ctrl-Shift-Enter My value for B1 is 10 and my array is {1,5,4,2,7} so in this case no value is greater than 1

2条回答
  •  暗喜
    暗喜 (楼主)
    2021-01-15 11:00

    Try using SMALL instead of MIN, i.e.

    =SMALL(IF(A1:A5>B1,A1:A5),1)

    Unlike MIN the SMALL function will return an error [#NUM!] for your example

    ....or if you want a text value instead of an error then use IFERROR function, too, i.e.

    =IFERROR(SMALL(IF(A1:A5>B1,A1:A5),1),"None")

提交回复
热议问题