CREATE TABLE STUDENT (LName VARCHAR2, PRESIDENT_Vote VARCHAR2, Advisor VARCHAR2)
CREATE TABLE VOTING_RECORD (Id VARCHAR2)

Find the distinct last names of all the students who have president votes and whose advisor is 8741.
SELECT DISTINCT T1.LName FROM STUDENT AS T1 JOIN VOTING_RECORD AS T2 ON T1.StuID = PRESIDENT_Vote INTERSECT SELECT DISTINCT LName FROM STUDENT WHERE Advisor = "8741"
SELECT DISTINCT "T1"."LName" FROM "STUDENT" "T1" JOIN "VOTING_RECORD" "T2" ON "PRESIDENT_Vote" = "T1"."StuID" INTERSECT SELECT DISTINCT "LName" FROM "STUDENT" WHERE "8741" = "Advisor"