From 76ec77f7dd8501bb7e7750ea534dff7c3f2168ce Mon Sep 17 00:00:00 2001 From: Kris Date: Sat, 25 May 2024 22:15:44 +0200 Subject: [PATCH] :card_file_box: add `id, arrival, departure` index to `stopovers` (#2599) --- ...val_departure_index_to_train_stopovers.php | 20 +++++++++++++++++++ 1 file changed, 20 insertions(+) create mode 100644 database/migrations/2024_05_25_000001_add_trip_id_arrival_departure_index_to_train_stopovers.php diff --git a/database/migrations/2024_05_25_000001_add_trip_id_arrival_departure_index_to_train_stopovers.php b/database/migrations/2024_05_25_000001_add_trip_id_arrival_departure_index_to_train_stopovers.php new file mode 100644 index 000000000..243ffd7ee --- /dev/null +++ b/database/migrations/2024_05_25_000001_add_trip_id_arrival_departure_index_to_train_stopovers.php @@ -0,0 +1,20 @@ +index(['trip_id', 'arrival_planned', 'departure_planned'], 'index_trip_id_arrival_departure'); + }); + } + + public function down(): void { + Schema::table('train_stopovers', static function(Blueprint $table) { + $table->dropIndex('index_trip_id_arrival_departure'); + }); + } +};