Sorting of a Arraylist with multiple elements with sort order
posted 7 years ago
I have a bean which has objects such as 1. SSN 2. TransferDate 3. FirstName 4. City
We are displaying these values on a jsp page. Now I am adding let's say 50 bean objects into a arraylist or a tree map or some list. How do I sort programatically which is done on the database usually. Let's see this sql: "Select SSN, TransferDate, FirstName, City from Employee orderby TransferDate DESC, City ASC, FirstName DESC, SSN ASC"