I have this select statement that gives me a list of students enrolled in a section. I have another select statement that gives me a list of students who are family reps for the school. All siblings at the school have a family_id. What I want to do is that if sibling1 in a section has another sibling (sibling2) who is the family rep, sibling 1 should not be included/removed from the section list.
I don't know how to write the sql query for this do not include/remove logic. What should I use? It cannot be union.