Updated code to reflect DB changes. Still not working...