Both the methods explained above are well and good. The
first one does not use any oracle function. Where it is explicitly asked not to
use any functions this approach can be followed.
But the second approach does the same through RANK () OVER
() function. Many other useful facts about the RANK () OVER () function can be
revealed by exploring it more.