Skip to content

Instantly share code, notes, and snippets.

View sansani4's full-sized avatar

Sasha sansani4

View GitHub Profile
@danielrolfe
danielrolfe / SitecoreEmptyRecycleBin.sql
Created September 17, 2020 21:42
Simple SQL script to delete the recycle bin rows from the Sitecore Archive tables. Use it at your own risk!
declare @CleanupList table(ArchivalId uniqueidentifier)
declare @ArchivalId uniqueidentifier
insert into @CleanupList(ArchivalId)
select ArchivalId
from dbo.Archive
where ArchiveName = 'recyclebin'
while(1 = 1)
begin
set @ArchivalId = NULL
select top (1) @ArchivalId = ArchivalId