ANSI SQL: Ordering results by picking some certain values of the columns

86 views Asked by At

I'm catching up on ANSI SQL, and got stuck with a theoretically easy question that I can't figure out myself. I hope someone can give me a hand.

How can i do to order results of a query by some certain values of a column?

I just need a hand to figure how to include the "place it at the bottom" clausule with chemistry and physics, due i can not include a logical expression in the ORDER BY clausule.

Thanks.

..................

table nobel ( winner, yr, subject)

Show the 1984 winners and subject ordered by subject and winner name; but list chemistry and physics last.

https://sqlzoo.net/wiki/SELECT_from_Nobel_Tutorial#Chemistry_and_Physics_last

SELECT winner, subject
FROM nobel
WHERE yr = 1984 ORDER BY <......>, subject, winner;
0

There are 0 answers