database: stations: make 'ds100' column optional.

HAFAS stations do not necessarily have ds100 codes
This commit is contained in:
Birte Kristina Friesel 2023-07-22 18:03:46 +02:00
parent 3d51395d39
commit 9209cb292e
No known key found for this signature in database
GPG key ID: 19E6E524EBB177BA

View file

@ -1803,6 +1803,18 @@ my @migrations = (
}
);
},
# v44 -> v45
# prepare for HAFAS support: many HAFAS stations do not have DS100 codes
sub {
my ($db) = @_;
$db->query(
qq{
alter table stations alter column ds100 drop not null;
update schema_version set version = 45;
}
);
},
);
# TODO add 'hafas' column to in_transit (and maybe journeys? undo/redo needs something to work with...)