UPDATE T_LS SET LASTVERIFIED = sysdate WHERE FULLPATH in (SELECT FULLPATH FROM T_LS_TMP) and LASTVERIFIED = (SELECT max(LASTVERIFIED) FROM T_LS);