Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

spark 语法下,coalesce和grouping sets一起用会直接报错 #25

Open
kyo21st opened this issue Nov 28, 2024 · 1 comment
Open

Comments

@kyo21st
Copy link

kyo21st commented Nov 28, 2024

解析如下spark sql会直接报错
INSERT OVERWRITE
TABLE vup.ads_vendor_summary PARTITION (dt = '${dt}')
--数据日期当天下单订单轻度汇总数据
SELECT
store_id,
COALESCE(department_id, 0) as department_id,
SUM(order_num) AS order_num
FROM
vup.ads_vendor_detail
WHERE
dt = '${dt}'
GROUP BY
store_id,
COALESCE(department_id, 0) GROUPING SETS (
(store_id, COALESCE(department_id, 0)),
(COALESCE(department_id, 0))
);

@melin
Copy link
Owner

melin commented Dec 2, 2024

spark 是否支持?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants