Fixed some entity relationship definition