Microsoft
Software
Hardware
Network
Question : Query: order within group
I have a table of data that has one field that is a groupID, and a field with a count.
So, what I'm trying to do is sort the table by group, and then order it within the group. I know I can do this with a report, but I'm having trouble with the SQL query; I'd rather just export the query results.
I've tried
SELECT tblList.*
FROM tblList
GROUP BY tblList.GroupID
ORDER BY tblList.RankAmt;
but I'm not getting any result. Is this one of those "You can't do that" things?
ep
Answer : Query: order within group
Now, not sure what you want yet ... but this sorts first by Group, then by RankAmt:
SELECT tblList.GroupID, tblList.RankAmt
FROM tblList
ORDER BY tblList.GroupID, tblList.RankAmt;
mx
Random Solutions
Calling a secure web servie with WCF client
Exporting to Excel From Visual Foxpro Excel Object Creating 2 Digit Year, Not 4 Digit
Purge Deleted items from database immediatly after message recall
Web Services Cross Browser Support
csv delimeter problem when importing to adp
CPropertySheet vs. CTabCtrl
How to use Decimal Data Type in VBA code
Excel Date column - autopopulate with today's date or incrementing date (part 2)
Need a SSIS walk through help on downloading an Excel file using a url
Entension vs Regular Dll in MFC?