I\'m trying to write a query that will list student(s) enrolled with the maximum total credit points.
Here is my query:
SELECT s.S_ID, s.S_LAS
You may want to tackle this by just using the group by and Sum(), and retrieve the result with an order by sum() with limit 1 or more depending on how many students your want.
This would eliminate the outer subquery.