select b.nomeAluno from( select matricula from tbHistoria where matricula NOT IN( select matricula from tbMatematica)) a, tbAluno b where a.matricula - b.matricula
Essa consulta SQL pode ser otimizada obtendo-se o mesmo resultado, empregando-se a seguinte expressão: