Beginning MySQL Tutorial One of the fastest SQL (Structured Query Language) database servers currently on the market is the MySQL server, developed by T.c.X. DataKonsultAB. MySQL, available for download at http://www.mysql.com, offers the data base programmer with an array of options and capabilities rarely seen in other database servers. What's more, MySQL is free of charge for those wishing to use it for private and commercial use.
| Name: |
David |
| Subject: |
ranking rows in a table |
| Date: |
10-31-1999 01:16AM |
Iknow you can order the results of a query with order by, but is there a one line sql query to retrieve the rank of a
particular entry? you can do it in two lines with:
select score from people where name = "David"
and then save the result and do:
select count(*)+1 from people where score > savedscore
But I'd like to do it in one line if possible. Thanks for any help.
|
Other posts in this thread:
| Top | | ranking rows in a table | David | 10-31-1999 01:16AM |
Reply to this post:
|
 |
Visit the MySQL Forum!
New On DevShed:
Hot Forum Topics:
|