Curse of old code - TrainUID was stripping the lead character so we had the wrong id in the db & json. This might have been why I had problems with the primary keys earlier