Is your feature request related to a problem or challenge? Please describe what you are trying to do.
PostgreSQL, SparkSQL and Oracle support using GROUPING functions to specify the null is from subtotal or from original
data.
https://www.postgresql.org/docs/15/functions-aggregate.html#FUNCTIONS-HYPOTHETICAL-TABLE
Databricks SparkSQL
https://docs.databricks.com/sql/language-manual/functions/grouping.html
Oracle
https://oracle-base.com/articles/misc/rollup-cube-grouping-functions-and-grouping-sets#grouping
Describe the solution you'd like
Describe alternatives you've considered
Additional context