debugged db, now onto the rest