0
I need to mount a query that displays the name of all categories, and in front of each name the total number of products.
The tables are:
Categorias (cat_codigo, cat_nome)
Produtos (pro_codigo, pro_codigo_categoria pro_nome)
Exemplo:
Parafusos (58)
Brocas (42)
Chaves (33)
I know how to make the connections between the two tables, but I’m in doubt about getting the full amount:
select * from categorias CAT LEFT JOIN produtos PRO ON CAT.cat_codigo=PRO.pro_codigo_categoria
thank you very much! that’s right.
– Eduardo
For nothing heheh !
– Lucas Brogni
If possible mark as solution that there is marked as solved... hugs.
– Lucas Brogni