UPDATE 
  cscart_lock_keys 
SET 
  expiry_at = UNIX_TIMESTAMP(NOW()) + 30, 
  token = '61FraoKbYUlZ7N27irDlRxqSvJQRGE7WA01oTs8OHjs=' 
WHERE 
  key_id = '922d8e1477f4feeecf287da09b76de2bb813ed7a54feb5360782ad7bb04144b4' 
  AND (
    token = '61FraoKbYUlZ7N27irDlRxqSvJQRGE7WA01oTs8OHjs=' 
    OR expiry_at <= UNIX_TIMESTAMP(NOW())
  )

Query time 0.00030