filled in many to many and one to many functions