2010-09-29 13:39:33 |
Julian Edwards |
description |
This is currently done with some SQL, like this below, but we'd much rather do it in code.
update libraryfilealias
set expires = now() - '30 days'::interval
from
archive, binarypackagefile, binarypackagepublishinghistory, distroseries, distroarchseries
where
archive.purpose = 1
AND binarypackagepublishinghistory.archive = archive.id
AND binarypackagepublishinghistory.status NOT IN (1,2)
AND binarypackagefile.binarypackagerelease = binarypackagepublishinghistory.binarypackagerelease
AND binarypackagefile.libraryfile = libraryfilealias.id
AND libraryfilealias.expires is NULL
AND distroseries.id = distroarchseries.distroseries
AND distroarchseries.id = binarypackagepublishinghistory.distroarchseries
AND distroseries.name = 'intrepid'
; |
This is currently done with some SQL, but we'd much rather do it in code.
|
|