UPDATE 
  cscart_lock_keys 
SET 
  expiry_at = UNIX_TIMESTAMP(NOW()) + 30, 
  token = 'MzchUGyDJR6dwAnpEt23qamljwo2hN/lAo9Yq0Or5PU=' 
WHERE 
  key_id = '852214aa991891e22c35e5b64fbdb4ff71bdc79446be011530953e0103e19d72' 
  AND (
    token = 'MzchUGyDJR6dwAnpEt23qamljwo2hN/lAo9Yq0Or5PU=' 
    OR expiry_at <= UNIX_TIMESTAMP(NOW())
  )

Query time 0.00033