model update to match sql