UPDATE 
  cscart_lock_keys 
SET 
  expiry_at = UNIX_TIMESTAMP(NOW()) + 30, 
  token = 'oqQxsLR5+YmH5XD2GwvjUy3G+T2/lsKRW6APPF3wctI=' 
WHERE 
  key_id = '35319ec3f7091114c648decca971253c2397426e62447b5b9173b7569afddfa6' 
  AND (
    token = 'oqQxsLR5+YmH5XD2GwvjUy3G+T2/lsKRW6APPF3wctI=' 
    OR expiry_at <= UNIX_TIMESTAMP(NOW())
  )

Query time 0.00041