Question · SQL and MySQL course · Module 10: Transactions and advanced SQL
The RANK function
How does RANK() differ from ROW_NUMBER()?
Answer options
- RANK() always numbers from the end, while ROW_NUMBER() from the start
- RANK() gives the same rank to rows with an equal value and skips the next rank (1, 2, 2, 4)
- RANK() works only on text, while ROW_NUMBER() only on numbers
- There is no difference - they are synonyms
You can check the correct answer by solving this task in the CodeWorlds game.