change lines for table function