Establishing relationship betwen models