UPDATE
cscart_lock_keys
SET
expiry_at = UNIX_TIMESTAMP(NOW()) + 30,
token = 'vmFBp5MjHon0jaW92Pzq6vyr2H/8iF2+Tr5NDDFxoLo='
WHERE
key_id = 'f935d95dab5b361a089d865ca5bb17f7a0e99e8403cf7f34a077d1b8468d4084'
AND (
token = 'vmFBp5MjHon0jaW92Pzq6vyr2H/8iF2+Tr5NDDFxoLo='
OR expiry_at <= UNIX_TIMESTAMP(NOW())
)