mirror of
https://github.com/bitwarden/server.git
synced 2024-11-22 12:15:36 +01:00
delete ciphers in smaller batches. ref #18
This commit is contained in:
parent
b04843b124
commit
2bc7799f3c
@ -6,12 +6,18 @@ BEGIN
|
||||
|
||||
BEGIN TRANSACTION User_DeleteById
|
||||
|
||||
DECLARE @BatchSize INT = 100
|
||||
WHILE @BatchSize > 0
|
||||
BEGIN
|
||||
DELETE
|
||||
FROM
|
||||
[dbo].[Cipher]
|
||||
WHERE
|
||||
[UserId] = @Id
|
||||
|
||||
SET @BatchSize = @@ROWCOUNT
|
||||
END
|
||||
|
||||
DELETE
|
||||
FROM
|
||||
[dbo].[Device]
|
||||
|
Loading…
Reference in New Issue
Block a user