fixing sort table requires