select id, row_number() over (partition by id order by up...

0

Please login or register to vote for this query.

(click on this box to dismiss)

Ask Ubuntu

Q&A for Ubuntu users and developers

select id,
row_number() over (partition by id order by upvotes desc) as num
from users
where id in (998692, 6309, 512251)
--order by upvotes desc

Enter Parameters

Options:
Switch to meta site
loading Hold tight while we fetch your results