Refactoring: create useful procedure for table creating.