add func to get relationship