UPDATE 
  cscart_lock_keys 
SET 
  expiry_at = UNIX_TIMESTAMP(NOW()) + 30, 
  token = 'o/RpDrRim1NAfpEEzSPjVorXm8WUYXE9MD4dtw9dRJE=' 
WHERE 
  key_id = 'f96b3a909379f99ca83dd8db8673035177c78439d28b073ad55b53863d5c6a4b' 
  AND (
    token = 'o/RpDrRim1NAfpEEzSPjVorXm8WUYXE9MD4dtw9dRJE=' 
    OR expiry_at <= UNIX_TIMESTAMP(NOW())
  )

Query time 0.00017