#1
  1. No Profile Picture
    Contributing User
    ASP Explorer (0 - 99 posts)

    Join Date
    Nov 2007
    Location
    Israel
    Posts
    37
    Rep Power
    11

    Is there a smarter way to get maximum


    get a+b on the maximum record:

    mySQL="SELECT a,b FROM tbl WHERE b=(SELECT Max(b) FROM tbl)"

    ?
  2. #2
  3. Unholy Moderator
    ASP Mastermind (5000+ posts)

    Join Date
    Oct 2003
    Location
    In hell, where did you think?
    Posts
    12,026
    Rep Power
    662
    Have you tried just doing:
    Code:
    SELECT MAX(b) FROM Table1

Similar Threads

  1. How to get the maximum number of an array column?
    By zwieback89 in forum ASP Development
    Replies: 4
    Last Post: December 29th, 2006, 11:45 AM
  2. Maximum Screen Resolution
    By DavieCooper in forum ASP Free Lounge
    Replies: 7
    Last Post: December 8th, 2006, 06:28 PM
  3. Replies: 0
    Last Post: March 2nd, 2005, 04:55 AM
  4. ASP Script Timeout Maximum
    By hominamad in forum Microsoft IIS
    Replies: 4
    Last Post: February 5th, 2004, 08:06 AM
  5. Maximum line length for database output in table
    By MrBlacksmith in forum ASP Development
    Replies: 6
    Last Post: October 7th, 2003, 05:36 AM

IMN logo majestic logo threadwatch logo seochat tools logo