diff --git a/query-languages/m/m-spec-operators.md b/query-languages/m/m-spec-operators.md index 3847fbeac..b9e1acf86 100644 --- a/query-languages/m/m-spec-operators.md +++ b/query-languages/m/m-spec-operators.md @@ -619,15 +619,13 @@ The following holds when evaluating an expression containing the relational oper * Errors raised when evaluating the `x` or `y` operand expressions are propagated. -* The values produced by evaluating both the `x` and `y` expressions must be a number, date, datetime, datetimezone, duration, logical, null or time value. Otherwise, an error with reason code `"Expression.Error"` is raised. +* The values produced by evaluating both the `x` and `y` expressions must be a binary, date, datetime, datetimezone, duration, logical, number, null, text or time value. Otherwise, an error with reason code `"Expression.Error"` is raised. -* If either or both operands are `null`, the result is the `null` value. +* Both operands must be the same kind of value or `null`. Otherwise, an error with reason code `"Expression.Error"` is raised. -* If both operands are logical, the value `true` is considered to be greater than `false`. +* If either or both operands are `null`, the result is the `null` value. -* If both operands are durations, then the values are compared according to the total number of 100-nanosecond ticks they represent. - -* Two times are compared by comparing their hour parts and, if equal, their minute parts and, if equal, their second parts. +* Two binaries are compared byte by byte. * Two dates are compared by comparing their year parts and, if equal, their month parts and, if equal, their day parts. @@ -635,6 +633,10 @@ The following holds when evaluating an expression containing the relational oper * Two datetimezones are compared by normalizing them to UTC by subtracting their hour/minute offset and then comparing their datetime components. +* Two durations are compared according to the total number of 100-nanosecond ticks they represent. + +* Two logicals are compared such that `true` is considered to be greater than `false`. + * Two numbers `x` and `y` are compared according to the rules of the IEEE 754 standard: * If either operand is `#nan`, the result is `false` for all relational operators. @@ -648,6 +650,11 @@ The following holds when evaluating an expression containing the relational oper * A `#infinity` value is considered greater than all other number values, but equal to another `#infinity`. +* Two texts are compared by using a character-by-character ordinal, case-sensitive, culture-insensitive comparison. + +* Two times are compared by comparing their hour parts and, if equal, their minute parts and, if equal, their second parts. + + ## Conditional logical operators The `and` and `or` operators are called the conditional logical operators.