mirror of
https://github.com/derf/travelynx
synced 2024-12-11 13:33:00 +00:00
Database: create index on real_departure to speed up latest journey queries
This commit is contained in:
parent
6c343f2f68
commit
6ca55f83b1
1 changed files with 12 additions and 2 deletions
|
@ -1903,9 +1903,19 @@ my @migrations = (
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
},
|
},
|
||||||
);
|
|
||||||
|
|
||||||
# TODO add 'hafas' column to in_transit (and maybe journeys? undo/redo needs something to work with...)
|
# v48 -> v49
|
||||||
|
# create indexes for common queries
|
||||||
|
sub {
|
||||||
|
my ($db) = @_;
|
||||||
|
$db->query(
|
||||||
|
qq{
|
||||||
|
create index uid_real_departure_idx on journeys (user_id, real_departure);
|
||||||
|
update schema_version set version = 49;
|
||||||
|
}
|
||||||
|
);
|
||||||
|
},
|
||||||
|
);
|
||||||
|
|
||||||
sub sync_stations {
|
sub sync_stations {
|
||||||
my ( $db, $iris_version ) = @_;
|
my ( $db, $iris_version ) = @_;
|
||||||
|
|
Loading…
Reference in a new issue