I've the below result
VendorName | IncidentID | IncidentStatus | IncidentDate ------------------------------------------------------- XYZ | 100 | Open | 02-JUN-2011 XYZ | 101 | Open | 03-JUN-2011 ABC | 102 | Open | 01-JUN-2011 XYZ | 103 | Open | 01-APR-2011 ABC | 105 | Open | 05-JUN-2011 I want to order VendorName which has latest incident. Vendor ABC has the latest incident hence it should come first with all other incident for same vendor and then next Vendor with all respective incident in descending order.The desired result is like this -
VendorName | IncidentID | IncidentStatus | IncidentDate ------------------------------------------------------- ABC | 105 | Open | 05-JUN-2011 ABC | 102 | Open | 01-JUN-2011 XYZ | 101 | Open | 03-JUN-2011 XYZ | 100 | Open | 02-JUN-2011 XYZ | 103 | Open | 01-APR-2011 ORDER BY IncidentDate desc, VendorName doesn't give the desired output. Any help ?