UPDATE
cscart_lock_keys
SET
expiry_at = UNIX_TIMESTAMP(NOW()) + 30,
token = 's9BPTb/QKKgO6NXgdjzg+zGRwj5tkBO8Rtvcf4KvY78='
WHERE
key_id = '28c2319baf5568e0f13d51000ed2be3319eba4e1ea693d5400fae3b8ae022056'
AND (
token = 's9BPTb/QKKgO6NXgdjzg+zGRwj5tkBO8Rtvcf4KvY78='
OR expiry_at <= UNIX_TIMESTAMP(NOW())
)