How to sort a query result array

I have a array with results from a query from regular tables, for example:\[code\]id | Name | Department | Location | Email | Phone | Type | ..........and so on\[/code\]I have the results in a query array, I can get the default query sorted, but I would like to ability to be able to resort that array as needed without having to keep re-reading data from the server, to cut down on traffic / speed things up.Is there a native function that does that so I can go like: \[code\]sort(array by department ascending)display array in nice format\[/code\]Any ideas?
 
Back
Top