UPDATE
cscart_lock_keys
SET
expiry_at = UNIX_TIMESTAMP(NOW()) + 30,
token = 'sz0Er7jAHbCu0xc1q5/OeR39JvdWTsCv/rHBCbiKaTA='
WHERE
key_id = '93dc34c3c8e4fa46bac7ae5bce7ada07f19b39f630fe3c79c64ad84b657f6739'
AND (
token = 'sz0Er7jAHbCu0xc1q5/OeR39JvdWTsCv/rHBCbiKaTA='
OR expiry_at <= UNIX_TIMESTAMP(NOW())
)