generated from fun-stack/example
-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
820df9a
commit 03c3fd6
Showing
2 changed files
with
6 additions
and
5 deletions.
There are no files selected for viewing
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
-- delete data older than one month. It's taking about 18 days to fill a gig, and we have | ||
-- 3 gig volume currently. That gives us 54 days. But 30 days is plenty and this gives us margin | ||
-- in case the rate of growth of data increases. | ||
delete from dataset where sampletime <= unixepoch()-30*24*60*60 | ||
delete from dataset where ids in (select distinct id from dataset where sampletime <= unixepoch()-28*24*60*60); | ||
update dataset set archived = 0; |