This week's book giveaway is in the Mac OS forum.
We're giving away four copies of a choice of "Take Control of Upgrading to Yosemite" or "Take Control of Automating Your Mac" and have Joe Kissell on-line!
See this thread for details.
The moose likes JDBC and the fly likes query for maximum marks Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


JavaRanch » Java Forums » Databases » JDBC
Bookmark "query for maximum marks" Watch "query for maximum marks" New topic
Author

query for maximum marks

Samanthi perera
Ranch Hand

Joined: Jan 08, 2010
Posts: 510
this is my question
Jan Cumps
Bartender

Joined: Dec 20, 2006
Posts: 2501
    
    8

Hi. Hope this is not your homework.


In your sql statement,
use the "max()" aggregation function to find the maximum marks,

and
to make the max() function aggregate on subject level,
group by subjectid by adding a "group by" clause.



OCUP UML fundamental and ITIL foundation
youtube channel
 
GeeCON Prague 2014
 
subject: query for maximum marks