sales_walk/sql/budgetc.sql

21 lines
395 B
MySQL
Raw Normal View History

2023-10-16 16:44:36 -04:00
WITH x AS (
SELECT
version,
oseas,
customer,
sum(sales_usd),
sum(pounds)
--string_agg(distinct mold,', ')
FROM b
left outer join rlarp.molds m ON
m.stlc = b.mold
WHERE
oseas = 2024
AND version = 'Forecats'
GROUP BY
version,
oseas,
customer
)
SELECT * FROM X