1
0
mirror of https://github.com/bitwarden/server.git synced 2025-06-30 15:42:48 -05:00

Update SQL files to be backwards compatible when adding columns (#1635)

* Update SQL files to be backwards compatible when adding columns

* Remove 'UseResetPasswordCustomOrg' SQL script
This commit is contained in:
Vince Grassia
2021-10-15 12:28:21 -04:00
committed by GitHub
parent 4d6b0c9106
commit 15eeb9d650
8 changed files with 18 additions and 6 deletions

View File

@ -50,6 +50,8 @@ UPDATE
[dbo].[Organization]
SET
[UseApi] = (CASE WHEN [PlanType] = 5 OR [PlanType] = 4 THEN 1 ELSE 0 END)
WHERE
[UseApi] IS NULL
GO
ALTER TABLE
@ -71,6 +73,8 @@ UPDATE
[dbo].[Organization]
SET
[ApiKey] = (SELECT [dbo].[SecureRandomString]())
WHERE
[ApiKey] IS NULL
GO
ALTER TABLE