adding table sorting