summaryrefslogtreecommitdiff
path: root/lib/Travelynx/Command/database.pm
diff options
context:
space:
mode:
authorBirte Kristina Friesel <derf@finalrewind.org>2023-10-01 07:11:58 +0200
committerBirte Kristina Friesel <derf@finalrewind.org>2023-10-01 07:11:58 +0200
commitaaeb81a5d230ca556fa950d0f9be0b98e85effcf (patch)
treedf292cdded847b4a7fac78e91b9050fd13c5fcbe /lib/Travelynx/Command/database.pm
parent2638dd36fba1fc3389138906a7436aba311dbe54 (diff)
store related stations; respect them when looking up connections
Diffstat (limited to 'lib/Travelynx/Command/database.pm')
-rw-r--r--lib/Travelynx/Command/database.pm17
1 files changed, 17 insertions, 0 deletions
diff --git a/lib/Travelynx/Command/database.pm b/lib/Travelynx/Command/database.pm
index b9074bc..d13b2a7 100644
--- a/lib/Travelynx/Command/database.pm
+++ b/lib/Travelynx/Command/database.pm
@@ -1929,6 +1929,23 @@ my @migrations = (
}
);
},
+
+ # v50 -> v51
+ # store related HAFAS stations
+ sub {
+ my ($db) = @_;
+ $db->query(
+ qq{
+ create table related_stations (
+ eva integer not null,
+ meta integer not null,
+ unique (eva, meta)
+ );
+ create index rel_eva on related_stations (eva);
+ update schema_version set version = 51;
+ }
+ );
+ },
);
sub sync_stations {