finish implementation of table