You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@superset.apache.org by "alesconti (via GitHub)" <gi...@apache.org> on 2026/02/03 08:02:12 UTC

[I] Percentage metrics column display only zero value [superset]

alesconti opened a new issue, #37627:
URL: https://github.com/apache/superset/issues/37627

   ### Bug description
   
   When I insert a column of type "percentage metrics", the column only shows zeros and doesn't calculate the percentage correctly. 
   This seems to happen when I simultaneously enable the "show summary" check on the column. 
   
   Do you know how I can fix this?
   
   ### Screenshots/recordings
   
   <img width="1961" height="1225" alt="Image" src="https://github.com/user-attachments/assets/5dd3d055-c75f-4719-8d60-e27215224391" />
   
   ### Superset version
   
   6.0.0
   
   ### Python version
   
   I don't know
   
   ### Node version
   
   16
   
   ### Browser
   
   Chrome
   
   ### Additional context
   
   _No response_
   
   ### Checklist
   
   - [ ] I have searched Superset docs and Slack and didn't find a solution to my problem.
   - [ ] I have searched the GitHub issue tracker and didn't find a similar bug report.
   - [ ] I have checked Superset's logs for errors and if I found a relevant Python stacktrace, I included it here as text in the "additional context" section.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


Re: [I] Percentage metrics column display only zero value [superset]

Posted by "rusackas (via GitHub)" <gi...@apache.org>.
rusackas commented on issue #37627:
URL: https://github.com/apache/superset/issues/37627#issuecomment-4738471022

   This is the Table-chart flavor of the non-additive totals problem we're tracking in #25747, and it's a useful data point that it still repros on 6.0.0 with "Show summary" on, so I carried that over. Closing in favor of #25747.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


Re: [I] Percentage metrics column display only zero value [superset]

Posted by "dosubot[bot] (via GitHub)" <gi...@apache.org>.
dosubot[bot] commented on issue #37627:
URL: https://github.com/apache/superset/issues/37627#issuecomment-3839749024

   <!-- Greeting -->
   Hi @alesconti! I'm [Dosu](https://go.dosu.dev/dosubot) and I’m helping the superset team.
   
   <!-- Answer -->
   This is a known limitation in Superset tables: percentage metrics often show zeros or incorrect values in the summary row because Superset aggregates percentages as regular numbers, rather than recalculating them based on the underlying data. This happens especially when the "show summary" option is enabled, since the summary row just sums the percentages instead of computing the correct aggregate percentage. There isn't a configuration option to change this behavior in Superset 6.0.0 [[source](https://github.com/apache/superset/issues/34350)].
   
   To improve percentage accuracy in your table, set the "Percentage metric calculation" option in the Table chart controls to "All records" instead of the default "Row limit". This makes Superset calculate percentages based on the full dataset, which helps avoid zeros and incorrect values (note: this may impact performance on large datasets) [[source](https://github.com/apache/superset/issues/34425)].
   
   For correct summary row values, define a custom metric in your dataset using SQL that calculates the percentage at the aggregation level you need (for example, `SUM(numerator) / SUM(denominator)`), so the summary row reflects the correct value [[source](https://github.com/apache/superset/issues/34350)].
   
   If you see zeros due to formatting, try increasing decimal precision in the column format or multiplying the value in SQL before formatting. If your metric references a Decimal datatype, casting it to Double Precision can also help avoid zero or division errors [[source](https://github.com/apache/superset/issues/28170)].
   
   Sometimes, re-creating the percentage metric column from scratch resolves configuration issues that cause formatting problems [[source](https://github.com/apache/superset/issues/36189)].
   
   If you have error logs or see unexpected behavior beyond these known limitations, feel free to share more details.
   
   
   <!-- Dosu Comment Footer -->
   *To reply, just mention [@dosu](https://go.dosu.dev/dosubot).*
   
   ---
   <sup>How did I do? [Good](https://app.dosu.dev/response-feedback/8ec117ef-882a-4282-b447-1fc41ae1ca6d?feedback_type=great_response) | [Irrelevant](https://app.dosu.dev/response-feedback/8ec117ef-882a-4282-b447-1fc41ae1ca6d?feedback_type=irrelevant_answer) | [Incorrect](https://app.dosu.dev/response-feedback/8ec117ef-882a-4282-b447-1fc41ae1ca6d?feedback_type=incorrect_sources) | [Verbose](https://app.dosu.dev/response-feedback/8ec117ef-882a-4282-b447-1fc41ae1ca6d?feedback_type=too_verbose) | [Hallucination](https://app.dosu.dev/response-feedback/8ec117ef-882a-4282-b447-1fc41ae1ca6d?feedback_type=hallucination) | [Report šŸ›](https://app.dosu.dev/response-feedback/8ec117ef-882a-4282-b447-1fc41ae1ca6d?feedback_type=bug_report) | [Other](https://app.dosu.dev/response-feedback/8ec117ef-882a-4282-b447-1fc41ae1ca6d?feedback_type=other)</sup>
   
   [![Chat with Dosu](https://dosu.dev/dosu-chat-badge.svg)](https://app.dosu.dev/a28d3c7e-a9d3-459e-9fb6-3a6f9ff4f357/ask?utm_source=github)&nbsp;[![Open in Cursor](https://dosu.dev/dosu-in-cursor.svg)](https://cursor.com/link/prompt?text=This%20is%20a%20known%20limitation%20in%20Superset%20tables%3A%20percentage%20metrics%20often%20show%20zeros%20or%20incorrect%20values%20in%20the%20summary%20row%20because%20Superset%20aggregates%20percentages%20as%20regular%20numbers%2C%20rather%20than%20recalculating%20them%20based%20on%20the%20underlying%20data.%20This%20happens%20especially%20when%20the%20%22show%20summary%22%20option%20is%20enabled%2C%20since%20the%20summary%20row%20just%20sums%20the%20percentages%20instead%20of%20computing%20the%20correct%20aggregate%20percentage.%20There%20isn%27t%20a%20configuration%20option%20to%20change%20this%20behavior%20in%20Superset%206.0.0%20%5B%5Bsource%5D%28https%3A//github.com/apache/superset/issues/34350%29%5D.%0A%0ATo%20improve%20percentage%20ac
 curacy%20in%20your%20table%2C%20set%20the%20%22Percentage%20metric%20calculation%22%20option%20in%20the%20Table%20chart%20controls%20to%20%22All%20records%22%20instead%20of%20the%20default%20%22Row%20limit%22.%20This%20makes%20Superset%20calculate%20percentages%20based%20on%20the%20full%20dataset%2C%20which%20helps%20avoid%20zeros%20and%20incorrect%20values%20%28note%3A%20this%20may%20impact%20performance%20on%20large%20datasets%29%20%5B%5Bsource%5D%28https%3A//github.com/apache/superset/issues/34425%29%5D.%0A%0AFor%20correct%20summary%20row%20values%2C%20define%20a%20custom%20metric%20in%20your%20dataset%20using%20SQL%20that%20calculates%20the%20percentage%20at%20the%20aggregation%20level%20you%20need%20%28for%20example%2C%20%60SUM%28numerator%29%20/%20SUM%28denominator%29%60%29%2C%20so%20the%20summary%20row%20reflects%20the%20correct%20value%20%5B%5Bsource%5D%28https%3A//github.com/apache/superset/issues/34350%29%5D.%0A%0AIf%20you%20see%20zeros%20due%20to%20formatting%2C%20try%20i
 ncreasing%20decimal%20precision%20in%20the%20column%20format%20or%20multiplying%20the%20value%20in%20SQL%20before%20formatting.%20If%20your%20metric%20references%20a%20Decimal%20datatype%2C%20casting%20it%20to%20Double%20Precision%20can%20also%20help%20avoid%20zero%20or%20division%20errors%20%5B%5Bsource%5D%28https%3A//github.com/apache/superset/issues/28170%29%5D.%0A%0ASometimes%2C%20re-creating%20the%20percentage%20metric%20column%20from%20scratch%20resolves%20configuration%20issues%20that%20cause%20formatting%20problems%20%5B%5Bsource%5D%28https%3A//github.com/apache/superset/issues/36189%29%5D.%0A%0AIf%20you%20have%20error%20logs%20or%20see%20unexpected%20behavior%20beyond%20these%20known%20limitations%2C%20feel%20free%20to%20share%20more%20details.)&nbsp;[![Join Discord](https://img.shields.io/badge/join-5865F2?logo=discord&logoColor=white&label=)](https://go.dosu.dev/discord-bot)&nbsp;[![Share on X](https://img.shields.io/badge/X-share-black)](https://twitter.com/intent/tweet?
 text=%40dosu_ai%20helped%20me%20solve%20this%20issue!&url=https%3A//github.com/apache/superset/issues/37627)


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


Re: [I] Percentage metrics column display only zero value [superset]

Posted by "rusackas (via GitHub)" <gi...@apache.org>.
rusackas closed issue #37627: Percentage metrics column display only zero value
URL: https://github.com/apache/superset/issues/37627


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org