In railway transportation, each train needs to have a timetable that specifies which track at which time will be occupied by it. This task can be addressed by automatization techniques both in generating a timetable and in optimizing an existing one. In this paper, we give an overview on the state of the art of these techniques. We study the computation of a technically valid slot for a train that guarantees a (short) spatial and temporal way through the network. Furthermore, the construction of a cyclic timetable where trains operate e.g. every 60 minutes, and the simultaneous construction of timetables for multiple trains are considered in this paper. Finally, timetables also need to be robust against minor delays. We will review the state of the art in the literature for these aspects of railway timetabling with respect to models, solution algorithms, complexity results and applications in practice.