summaryrefslogtreecommitdiff
path: root/db/update.d
diff options
context:
space:
mode:
Diffstat (limited to 'db/update.d')
-rw-r--r--db/update.d/22_shifts.php5
1 files changed, 5 insertions, 0 deletions
diff --git a/db/update.d/22_shifts.php b/db/update.d/22_shifts.php
new file mode 100644
index 00000000..3055c778
--- /dev/null
+++ b/db/update.d/22_shifts.php
@@ -0,0 +1,5 @@
+<?php
+if(sql_num_query("SHOW INDEX FROM `ShiftEntry` WHERE `Key_name` = 'SID' AND `Column_name` = 'TID'") == 0) {
+ sql_query("ALTER TABLE `ShiftEntry` DROP INDEX `SID`, ADD INDEX `SID` ( `SID` , `TID` )");
+ $applied = true;
+}