SCHEDULE feed guidance

78 views
Skip to first unread message

Toby

unread,
Mar 27, 2026, 3:31:06 PM (9 days ago) Mar 27
to A gathering place for the Open Rail Data community
Hi all,

I'm new to RDM and am trying to create a timetable using the NWR schedule feed for a small project. For now, all I want get out of it is a list of passenger services planned to call at Barnstaple today using the full-update JSON file.

The only services out of Barnstaple today should be rail replacement buses. So far I've got a list of the permanent services and the rail replacements, though my issue is that only a couple of the permanent ones are marked as cancelled. I'm assuming that all of them should be marked as cancelled since they're not running today?

I'm only listing services where:
- Today is within the schedule start/end dates
- The schedule operates on a Sunday
- The signalling ID starts with 1 or 2/is 0B00/there's no ID at all
- Barnstaple is included in the service's stopping locations
- Q is not included in operating characteristics

Will the cancellations actually be in the schedule, am I filtering out the wrong things or am I missing something else entirely? Any dumbed-down guidance would be amazing. Many thanks!

scfy12

unread,
Mar 27, 2026, 5:31:03 PM (9 days ago) Mar 27
to openraildata-talk
Hello there,

It is good fun figuring this out - I am building my own project too.

For this weeks service, those services have been amended to start or terminate at Exeter Central.

Thus they will be still be running, but as an amended schedule.

The permanent schedule will have a combination of days run and date validity - the thing to match on is the schedule uid.

For example...

2R91 1733 Barnstaple to Exeter Central Permanent schedule with UID P33293 has been amended to start at Exeter St Davids today.

This is known as an overlay.

To pick up an overlay (or cancellation), comparison needs to be done again the uid for a P schedule and the dates that P schedule is valid for.

Thus is you look for a uid of P33293 valid for today, you will pick the permanent version and tne amended version.

This is also true of cancellations: 

2E95 2141 Barnstaple to Exeter St Davids is cancelled throughout - if you match on its uid of P31559 for today, you will pick up the P schedule and it's cancellation.

A quick guide on stp indicators
P = Permanent
O = Overlay
C = Cancellation
N = New

Permanent can be overlaid or cancelled. Thus if you match two schedules on a day, to select the one which actually applies some logic is needed to sort that out.

For P,  O, or C schedules, I have seen the lowest letter in the alphabet wins (whether this is by design or not, it makes the logic a little easier to think about).

New schedules are not associated with a permanent schedule - so the logic is simple.

Thus performing the query as you have it will look like permanent schedules have not been cancelled, but in fact the still operate between Exeter St Davids and Exeter Central which is an amendment rather than a cancellation.

It is a lot to get your head around. It was for me!

Kind regards

--
You received this message because you are subscribed to the Google Groups "A gathering place for the Open Rail Data community" group.
To unsubscribe from this group and stop receiving emails from it, send an email to openraildata-t...@googlegroups.com.
To view this discussion, visit https://groups.google.com/d/msgid/openraildata-talk/f3a7e6ca-f27e-4dee-91ee-e6bcb078650en%40googlegroups.com.

Ian Sargent

unread,
Mar 30, 2026, 8:42:14 AM (6 days ago) Mar 30
to A gathering place for the Open Rail Data community
Warning... Those STP indicators need to be read in conjunction with the third column of the BS record: BSN, BSR, BSD; to determine exactly what is happening.

scfy12

unread,
Mar 30, 2026, 9:33:57 AM (6 days ago) Mar 30
to openraildata-talk
Ah good catch! Thank you for sparing my blushes Ian.

I assumed this was for a full rather an update CIF!

Kind regards
Shaun


On Mar 30, 2026 at 13:42, Ian Sargent <sargenor...@gmail.com> wrote:

Warning... Those STP indicators need to be read in conjunction with the third column of the BS record: BSN, BSR, BSD; to determine exactly what is happening.


On Friday, 27 March 2026 at 21:31:03 UTC scfy12 wrote:
Reply all
Reply to author
Forward
0 new messages