Bernd P said:
But I prefer the SIGN() function
To each his own.
But philosophically, I think ">0" is the better choice. It clearly
indicates that we expect only values greater than zero to be valid.
When I saw SIGN, my first reaction was: "Why is the guy using SIGN? The
particular argument can never evaluate to -1. So what does he expect?"
Then I thought: "Okay, it works. But why use a function when an operator
will do just fine?" Then I remembered that IF() is treated like an
operator, not a function, so I thought perhaps that is true for all internal
functions. So there probably is no performance issue. Nonetheless, the use
of SIGN __looks__ inefficient there. And of course, it counts toward the
Excel 2003 nesting limit of 7.
But hey, y'can lead a horse to water, but y'can't make him drink.
----- original message -----
Since I suspect that Excel treats SIGN as an operator, not a bona fide
function with its concomitant overhead, it is unclear whether my
suggestion
is more efficient. But it requires 4 fewer keystrokes to type
![Smile :) :)](data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7)
.
Hello,
That is possible and also far better than just to add the OR criteria
checks.
But I prefer the SIGN() function - it is clearly showing that we deal
with OR criteria here. This is similar to the double unary minus
operator which clearly indicates a criterion check.
But let us keep in mind that we talk about Excel's biggest time
waster: SUMPRODUCT
Regards,
Bernd