refactor eod tables