Created
December 19, 2017 08:29
-
-
Save thespacedoctor/bbbff20ea87a4912f7a09770345998d5 to your computer and use it in GitHub Desktop.
[Archive Stale Transients in Marshall] Archive Old Objects from the Marshall Inbox #marshall
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- To count the objects before you archive them: | |
select * from transientBucketSummaries t, pesstoObjects p where p.marshallWorkflowLocation = "inbox" and p.transientBucketId=t.transientBucketId and t.dateAdded < "2016-04-15"; | |
-- and then to archive: | |
update transientBucketSummaries t, pesstoObjects p set p.marshallWorkflowLocation = "archive" where p.marshallWorkflowLocation = "inbox" and p.transientBucketId=t.transientBucketId and t.dateAdded < "2016-04-16"; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment