If I have two columns, one with very high cardinality and one with very low cardinality (unique # of values), does it matter in which order I group by?
Here\'s an ex
SQL is declarative.
In this case, you have told the optimiser how you want the data grouped and it works out how to do it.
It won't evaluate line by line (procedural) and look at one column first
The main place column order matters is for indexes. col1, col2 is not the same as col2, col1. At all.
col1, col2
col2, col1