Nth maximum value

Results 1 to 2 of 2

Thread: Nth maximum value

  1. #1
    Sujatha T Idiculla Guest

    Default Nth maximum value

    Can you please give a query that would return the nth maximum value of a column assuming that the value of n is passed as 8.<BR>We cannot use any back end specific function because we use 4 back ends.<BR><BR>Thanks,<BR>Sujatha

  2. #2
    Nathan Pond Guest

    Default RE: Nth maximum value

    What kind of database are you using? Can you use a stored procedure? If you have SQL 7 you could do something like:<BR><BR>Select Top 8 field From Table<BR><BR>then in ASP do rs.MoveLast to get to the 8th record. You could also write a stored procedure.<BR><BR>Nathan

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts