minor work on timetable using info from database