Created
May 25, 2019 11:56
-
-
Save PhilETaylor/26e59abfa4a0bd081267ea019795bf04 to your computer and use it in GitHub Desktop.
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
UPDATE bf_files AS NEWTABLE | |
INNER JOIN ( | |
SELECT | |
bf_files_last.filewithpath, | |
bf_files_last.suspectcontent, bf_files_last.falsepositive, | |
bf_files_last.encrypted FROM bf_files_last | |
LEFT JOIN | |
bf_files ON | |
bf_files_last.filewithpath = bf_files.filewithpath | |
WHERE | |
bf_files_last.currenthash = | |
bf_files.currenthash | |
AND | |
bf_files_last.filemtime = | |
bf_files.filemtime | |
AND | |
bf_files_last.fileperms = | |
bf_files.fileperms | |
AND | |
bf_files_last.filewithpath = | |
bf_files.filewithpath | |
) AS | |
OLDTABLE | |
ON | |
NEWTABLE.filewithpath = | |
OLDTABLE.filewithpath | |
SET | |
NEWTABLE.filewithpath = | |
OLDTABLE.filewithpath, | |
NEWTABLE.suspectcontent = | |
OLDTABLE.suspectcontent, | |
NEWTABLE.falsepositive = | |
OLDTABLE.falsepositive, | |
NEWTABLE.encrypted = | |
OLDTABLE.encrypted, | |
NEWTABLE.queued = 0 | |
WHERE | |
OLDTABLE.suspectcontent != 1 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment