fixing sort order values