Implement SetRelation.