UPDATE
cscart_lock_keys
SET
expiry_at = UNIX_TIMESTAMP(NOW()) + 30,
token = 'ODCe+x3zyoawWnMVEjAjXZnVmHj2Lk1/1qHhcJZzhsk='
WHERE
key_id = 'c5aa27d058517ea85de9c38eed949f9f418f01083439dd1cf25b8aee8da1be70'
AND (
token = 'ODCe+x3zyoawWnMVEjAjXZnVmHj2Lk1/1qHhcJZzhsk='
OR expiry_at <= UNIX_TIMESTAMP(NOW())
)