mirror of
https://github.com/Aurorastation/Aurora.3.git
synced 2025-12-21 07:32:02 +00:00
* Condense Database Migrations Condenses the Database Migrations into a new initial schema. Also adds some instructions to the Database Readme for existing setups. * Update readme/delete changed migrations since pr creation * Reworks a bit how the previous migrations are handled and updates the instructions accordingly * Expand the readme with baseline/migrate --------- Co-authored-by: Werner <Arrow768@users.noreply.github.com>
30 lines
585 B
SQL
30 lines
585 B
SQL
--
|
|
-- Implemented in PR #4026.
|
|
-- Adds a deleted_at column for mirrors.
|
|
-- Also adds indexes for speeding up search queries around the ban database.
|
|
--
|
|
|
|
ALTER TABLE `ss13_ban_mirrors`
|
|
ADD `deleted_at` DATETIME NULL DEFAULT NULL AFTER `extra_info`;
|
|
|
|
CREATE INDEX `idx_mirrors_isbanned` ON `ss13_ban_mirrors` (
|
|
`deleted_at`,
|
|
`ckey`,
|
|
`ip`,
|
|
`computerid`
|
|
);
|
|
|
|
CREATE INDEX `idx_mirrors_select` ON `ss13_ban_mirrors` (
|
|
`deleted_at`,
|
|
`ban_id`
|
|
);
|
|
|
|
CREATE INDEX `idx_ban_isbanned` ON `ss13_ban` (
|
|
`unbanned`,
|
|
`bantype`,
|
|
`expiration_time`,
|
|
`ckey`,
|
|
`computerid`,
|
|
`ip`
|
|
);
|