答案 0 :(得分:3)
select c.candidateId, c.candidatename,
count(sc.candidate_tbl_candidateId) as vote_count
from candidate_tbl c
left join student_tbl_has_candidate_tbl sc on sc.candidate_tbl_candidateId = c.candidateId
group by c.candidateId, c.candidatename