Created
December 5, 2013 12:44
-
-
Save tejasbubane/7804584 to your computer and use it in GitHub Desktop.
Remove records corresponding to some dates. To be done if something goes wrong and process files again
This file contains hidden or 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
| db.snapshot_date_logs.remove({"_id.trans_date": ISODate("2013-12-04T05:00:00Z")}) | |
| db.snapshot_date_logs.remove({"_id.trans_date": ISODate("2013-12-05T05:00:00Z")}) | |
| db.date_logs.remove({"_id.trans_date": ISODate("2013-12-05T05:00:00Z")}) | |
| db.date_logs.remove({"_id.trans_date": ISODate("2013-12-04T05:00:00Z")}) | |
| user_details.remove("trans_date":{"$gte":Time.parse("2013-12-04")}) | |
| filenames.remove("_id"=>"/s3-rbi/log/rails_log_analytics/log_metrics_2013-12-04-00.log") ... upto 24 and next date if necessary | |
| no need to change anything in items table since parser checks if open_id exists and only then inserts | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment