You want to sort by score desc, and use 'rownum' http://www.h2database.com/html/functions.html?highlight=rownum&search=row#rownum
<http://www.h2database.com/html/functions.html?highlight=rownum&search=row#rownum> Cheers Kerry On Sun, Oct 3, 2010 at 6:13 AM, shareproduct <[email protected]> wrote: > Assume I've a table game: > id---PlayerName---Score > 1 joe 1500 > 1 jack 1100 > 1 john 900 > 1 steve 100 > 1 bob 1000 > > > the rank of joe will be 1, bob 3 ... > > On Oct 2, 1:08 pm, Kerry Sainsbury <[email protected]> wrote: > > What is "a rank of of row"? Please post an example. > > > > Thanks > > > > On Sun, Oct 3, 2010 at 5:27 AM, shareproduct <[email protected]> > wrote: > > > Hello, > > > > > what's the fastest way to get rank of of row from a table with 20 > > > 000+ rows? > > > can someone please post a sql script > > > > > Thanks > > > > > -- > > > You received this message because you are subscribed to the Google > Groups > > > "H2 Database" group. > > > To post to this group, send email to [email protected]. > > > To unsubscribe from this group, send email to > > > [email protected]<h2-database%[email protected]> > <h2-database%[email protected]<h2-database%[email protected]> > > > > > . > > > For more options, visit this group at > > >http://groups.google.com/group/h2-database?hl=en. > > -- > You received this message because you are subscribed to the Google Groups > "H2 Database" group. > To post to this group, send email to [email protected]. > To unsubscribe from this group, send email to > [email protected]<h2-database%[email protected]> > . > For more options, visit this group at > http://groups.google.com/group/h2-database?hl=en. > > -- You received this message because you are subscribed to the Google Groups "H2 Database" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/h2-database?hl=en.
