added my own code for sorting tables
deleted test file