Your object contains a property called h_id, you're currently sorting by id which will parse to NaN resulting in a false return. Simply change a.id and b.id to a.h_id and b.h_id and it should work.
oh my gosh... I don't believe this......:blush:
thank you very much......