RX0652

Domain: Execution

Error message

%s: %s

In the message, %s marks a value that the engine fills in when it raises the error.

The story

Your multi-key sort did not say clearly which direction each key should go. Let's see how it works. When you sort rows by several labels, each key can go ascending or descending. The reverse argument controls that, and it has two lawful forms. Either one single truth value, which applies to every key, or a list of truth values with exactly one entry for each label in the by list. Now, suppose you sort by three labels and give a reverse list with two entries. What should happen with the third key? Ascending? Descending? Rush will not choose. A wrong default would sort your data incorrectly and look completely plausible. The same goes for a list member that is not a truth value, like a number or a text. So rush refuses, showing the reverse operand in the first slot and the lawful spellings in the second. For example, to sort by last name ascending, and then by age descending, you give a by list of two labels, and a reverse list of false and true. Match the counts, and the order is yours.

Text from the Rush engine's error catalogue.