mirror of
https://we.phorge.it/source/phorge.git
synced 2024-12-24 14:30:56 +01:00
0a77b0e53e
Summary: See T13193. See T13077. If we drop a column which is part of a UNIQUE KEY, MariaDB raises an error. This is probably a bad idea on our side anyway, but in this case it wasn't an obviously bad idea. To get around this: - Drop the unique key, if it exists, before dropping the column. - Explicitly add the new unique key afterward. Test Plan: Ran `bin/storage upgrade` locally without issue, but I'm on MySQL. Will follow up on T13193. Reviewers: amckinley Subscribers: PHID-OPKG-gm6ozazyms6q6i22gyam Differential Revision: https://secure.phabricator.com/D19624
2 lines
109 B
SQL
2 lines
109 B
SQL
ALTER TABLE {$NAMESPACE}_phriction.phriction_content
|
|
ADD UNIQUE KEY `key_version` (documentPHID, version);
|