Questão de Banco de Dados — SQL — FGV 2015
Banco de DadosSQL
- Código
- fg019420
- Banca
- FGV
- Órgão
- TJ-PI
- Ano
- 2015
- Nível
- Superior
- Cargo
- Analista Judiciário - Analista de Sistemas / Banco de Dados
O SQL que Thiago deve usar é:
- Aselect COUNT(*), p1.piloto from F1 p1, F1 p2 where p1.pontos > p2.pontos group by p1.piloto order by 1
- Bselect k+1,p1.piloto from F1 p1, k=0 order by p1.pontos
- Cselect (select COUNT(*) from F1where F1.pontos > p1.pontos),p1.pilotofrom F1 p1order by 1
- Dselect COUNT(*), p1.pilotofrom F1 p1, F1 p2, F1 p3where p1.pontos <= p2.pontosand p3.pontos > p1.pontosgroup by p1.pilotoorder by 1
- Eselect COUNT(*), p1.pilotofrom F1 p1, F1 p2where p1.pontos <= p2.pontosgroup by p1.pilotoorder by 1