fix table structure