UPDATE
cscart_lock_keys
SET
expiry_at = UNIX_TIMESTAMP(NOW()) + 30,
token = '5bsq1/wyYT3AYdMtoHp4FlboAbeq/roRVO+ZP3LBCBQ='
WHERE
key_id = '83ea7f8576bc3d1264c318af7316a132a0f385feb00fd65374b8cfab6e4319aa'
AND (
token = '5bsq1/wyYT3AYdMtoHp4FlboAbeq/roRVO+ZP3LBCBQ='
OR expiry_at <= UNIX_TIMESTAMP(NOW())
)