From: Ilan Berci Date: 2007-03-26T23:20:00+09:00 Subject: Re: sorting an array based on two attributes of objects Alex Young wrote: > > sorted_employees = employees.sort_by { |e| [ -e.salary, e.name ] } > > I can't think of a way offhand to have different lexicographic orderings > in the same sort, though. Doh!!!! Ofcourse! Ok.. more coffee for me.. ilan -- Posted via http://www.ruby-forum.com/.