Welcome to ORDER BY jungle

SQL is fun and not at all boring. The latest article by Markus Winand on Order by Has Come a Long Way sent me on quite a journey. First, set up a table called nums with one integer column and four rows: CREATE TABLE nums (a int ); INSERT INTO nums VALUES ( 0 ), ( 1 ), ( 2 ), ( 3 ); Try to guess what these two queries return. SELECT - a AS a FROM nums ORDER BY a; SELECT - a AS a FROM nums ORDER BY…