refactoring for table.
refactoring.