Is this easy

no it is not

select userName
    , score
 from resultsTable  as T
where userName = '$myUserName'
   or ( userName > '$myUserName'
           and ( select count(*)
                   from resultsTable
                  where userName > '$myUserName'
           and userName <= T.userName ) <= 5 )
   or ( userName < '$myUserName'
           and ( select count(*)
                   from resultsTable
                  where userName >= T.userName
           and userName < '$myUserName' ) <= 5 )
order by userName desc

rudy
http://r937.com/

____ � The WDVL Discussion List from WDVL.COM � ____
To Join wdvltalk, Send An Email To: mailto:[EMAIL PROTECTED] or
use the web interface http://e-newsletters.internet.com/discussionlists.html/
      Send Your Posts To: [email protected]
To change subscription settings, add a password or view the web interface:
http://intm-dl.sparklist.com/read/?forum=wdvltalk

________________  http://www.wdvl.com  _______________________

You are currently subscribed to wdvltalk as: [email protected]
To unsubscribe send a blank email to [EMAIL PROTECTED]
To unsubscribe via postal mail, please contact us at:
Jupitermedia Corp.
Attn: Discussion List Management
475 Park Avenue South
New York, NY 10016

Please include the email address which you have been contacted with.

Reply via email to