Atualização da query para retornar o nível correto dos produtos.
davinTI/app-dono-modulos/pipeline/head This commit looks good

This commit is contained in:
2026-05-07 16:38:03 -03:00
parent bbd48ea2f7
commit c5e8419894
+3 -2
View File
@@ -348,7 +348,7 @@ where 1 = 0`,
)
)
SELECT
'Categorias' AS canalapp,
x.tipo_nodo AS canalapp,
x.codigo AS cod_empresa,
@@ -422,6 +422,7 @@ where 1 = 0`,
SELECT
cat.codigo AS codigo,
cat.nome AS nomeempresaapp,
cat.tipo_nodo,
r.valor_meta_efetiva,
r.valor_venda,
CASE
@@ -453,7 +454,7 @@ where 1 = 0`,
GROUP BY
GROUPING SETS (
(x.codigo, x.nomeempresaapp),
(x.codigo, x.nomeempresaapp, x.tipo_nodo),
()
)