User's Rank Query..!

Discussion in 'Databases' started by gasper000, May 9, 2009.

  1. #1
    I have made a flash game that has a ranking system which allows the players to know the top 10 users ranked by score. That works fine but I'm trying to figure out a query that allows the player to know his own ranking if he's not listed in the top 10 players.

    The query I use for ranking the top 10 is:

    mysql_query ( "SELECT * FROM 'myscore' ORDER BY score DESC")
    Code (markup):
    Any ideas ?!
     
    gasper000, May 9, 2009 IP
  2. chisara

    chisara Peon

    Messages:
    141
    Likes Received:
    11
    Best Answers:
    0
    Trophy Points:
    0
    #2
    First the Ranking Top 10 query can be changed to
    mysql_query ( "SELECT * FROM 'myscore' ORDER BY score DESC LIMIT 10") This should use the bandwidth between SQL Server and App Server more efficient.
    For the other part it is handy to know the table structures you are using.
     
    chisara, May 11, 2009 IP
  3. manzoD15

    manzoD15 Guest

    Messages:
    126
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #3
    i was curious about the post. I didnt get it. but thanks for the post anyway.
     
    manzoD15, May 14, 2009 IP