UPDATE 
  cscart_lock_keys 
SET 
  expiry_at = UNIX_TIMESTAMP(NOW()) + 30, 
  token = 'VeGaSpQBMFN9suZYPiUOJvQZ4fQiDqk7V3q1P4dclio=' 
WHERE 
  key_id = '92506335d5f38efba819f4e20712d458639b3c8e1113e45ed6d2ce8b0c02ef65' 
  AND (
    token = 'VeGaSpQBMFN9suZYPiUOJvQZ4fQiDqk7V3q1P4dclio=' 
    OR expiry_at <= UNIX_TIMESTAMP(NOW())
  )

Query time 0.00047