UPDATE
cscart_lock_keys
SET
expiry_at = UNIX_TIMESTAMP(NOW()) + 30,
token = 'vTZ+CjUZpGvd4T24uCChmQFNJ/v0+m+BZ4WLOX3hW7A='
WHERE
key_id = 'b07cbc97ccb92014f46d831f9ac2a9d10b3dfee0dc3a91d9ec6a1a373cd73064'
AND (
token = 'vTZ+CjUZpGvd4T24uCChmQFNJ/v0+m+BZ4WLOX3hW7A='
OR expiry_at <= UNIX_TIMESTAMP(NOW())
)