mirror of
https://github.com/bitwarden/server.git
synced 2025-07-01 08:02:49 -05:00
[AC-1682] Reverted scripts back to enabling Flexible Collections to all existing Orgs
This commit is contained in:
@ -133,23 +133,9 @@
|
||||
SET `U`.`AccountRevisionDate` = UTC_TIMESTAMP();
|
||||
|
||||
-- Step 5: Set `FlexibleCollections` = 1 for all organizations that have not yet been migrated.
|
||||
UPDATE `Organization` AS `O`
|
||||
JOIN (
|
||||
SELECT DISTINCT `TG`.`OrganizationId`
|
||||
FROM `TempGroupsAccessAll` AS `TG`
|
||||
|
||||
UNION
|
||||
|
||||
SELECT DISTINCT `TU`.`OrganizationId`
|
||||
FROM `TempUsersAccessAll` AS `TU`
|
||||
|
||||
UNION
|
||||
|
||||
SELECT DISTINCT `OU`.`OrganizationId`
|
||||
FROM `TempUserManagers` AS `OU`
|
||||
) AS `TempOrgIds` ON `O`.`Id` = `TempOrgIds`.`OrganizationId`
|
||||
SET `O`.`FlexibleCollections` = 1
|
||||
WHERE `O`.`FlexibleCollections` = 0;
|
||||
UPDATE `Organization`
|
||||
SET `FlexibleCollections` = 1
|
||||
WHERE `FlexibleCollections` = 0;
|
||||
|
||||
-- Step 6: Drop the temporary tables
|
||||
DROP TEMPORARY TABLE IF EXISTS `TempGroupsAccessAll`;
|
||||
|
Reference in New Issue
Block a user