A method for detecting a crossing of a track section of a track of a railway of a rail network by a rail vehicle, wherein in said method - at least one track signature is provided in a database for each selected non-adjacent track sections of tracks of the railway, said track signature describing the course and/or the change of at least one location-dependent physical quantity acting on the rail vehicle when driving on the respective track section and thus characterizing the track section, - wherein the selection of track sections is based on distinguishable track signatures of track sections of the tracks of an area of the rail network, - the at least one physical quantity is detected and recorded by a sensor system of the rail vehicle when crossing the railway, - it is detected by comparing the recorded course of the at least one physical quantity and/or its change to the track signatures provided in the database whether the rail vehicle crosses or leaves one of the track sections for which there is a track signature in the database, and - a true signal is output if the recorded current course of the at least one physical quantity corresponds to one of the track signatures in the database or deviates therefrom by less than a predetermined maximum deviation threshold, - wherein the magnetic field alone or the magnetic field in combination with vibrations and/or with the degree of curvature and/or with the position angle of the track section are used as one of the physical quantities describing the track signature, characterized in that the speed of the rail vehicle in the track sections, for which a signature is provided, is measured, in that the track signatures provided for selected track sections are updated in the database based on the course of location and time of the at least one physical quantity currently determined when crossing a respective track section and/or the location- and/or time-dependent change of the at least one physical quantity, if the currently determined track signature differs from the track signature provided for the respective track section by more than a minimum deviation threshold that is smaller than the maximum deviation threshold. - at least one track signature is provided in a database for each selected non-adjacent track sections of tracks of the railway, said track signature describing the course and/or the change of at least one location-dependent physical quantity acting on the rail vehicle when driving on the respective track section and thus characterizing the track section, - wherein the selection of track sections is based on distinguishable track signatures of track sections of the tracks of an area of the rail network, - the at least one physical quantity is detected and recorded by a sensor system of the rail vehicle when crossing the railway, - it is detected by comparing the recorded course of the at least one physical quantity and/or its change to the track signatures provided in the database whether the rail vehicle crosses or leaves one of the track sections for which there is a track signature in the database, and - a true signal is output if the recorded current course of the at least one physical quantity corresponds to one of the track signatures in the database or deviates therefrom by less than a predetermined maximum deviation threshold, - wherein the magnetic field alone or the magnetic field in combination with vibrations and/or with the degree of curvature and/or with the position angle of the track section are used as one of the physical quantities describing the track signature, <EOS>