Pular para o conteúdo principal

Questão de Banco de Dados — SQL — NC-UFPR 2015

Banco de DadosSQL
Código
qq144823
Banca
NC-UFPR
Órgão
ITAIPU BINACIONAL
Ano
2015
Nível
Superior
Cargo
Computação ou Informática - Sistemas
Assinale a alternativa cujo comando está com a sintaxe correta.
  1. Aselect chavevendedor, sum(valorvendas) from vendas where (chavefilial=1) and (sum(valorvendas)>=1000000) order by sum(valorvendas)
  2. Bselect chavevendedor, sum(valorvendas) from vendas where chavefilial=1 having sum(valorvendas)>=1000000 order by sum(valorvendas)
  3. Cselect chavevendedor, sum(valorvendas) from vendas group by chavevendedor having sum(valorvendas)>=1000000 where chavefilial=1 order by sum(valorvendas)
  4. Dselect chavevendedor, sum(valorvendas) from vendas where chavefilial=1 group by chavevendedor having sum(valorvendas)>=1000000 order by sum(valorvendas)
  5. Eselect chavevendedor, sum(valorvendas) from vendas where chavefilial=1 having sum(valorvendas)>=1000000 group by chavevendedor order by sum(valorvendas)
Revelar gabarito e comentário

GabaritoD — select chavevendedor, sum(valorvendas) from vendas where chavefilial=1 group by chavevendedor having sum(valorvendas)>=1000000 order by sum(valorvendas)

Link permanente: /questoes/qq144823