Hello.
I need to present the average cost, the lowest cost and the highest cost of all products and present the total of verified products.
The table I have is this:
Does anyone know how I love it?
1 answer
1
select max(custoun) as maior_custo_unitario,
avg(custoun) as custo_unitario_medio,
min(custoun) as menor_custo_unitario,
count(codprod) as qtde_total_produtos
from nome_tabela
Thank you very much Raphael!!
– Wagner
Glad I could help :)
– Raphael Godoi