Creating a calculated column in beast mode results in data being split up

Hi all - I am new to Domo and experiencing some issues displaying desired results in a bullet chart.
I have a beast mode calculation where it provides a value if one criteria is met, and another when a different criteria is met. In my bullet bar graph, when I select both criterias in the filters, values are now split into two sets where I'm expecting one consolidated total.
I also tried capturing both criterias in the case statement but it still displayed both sets. Am I writing the beast calculation incorrectly or should I be creating this formula in the ETL?
Bullet chart - results
Bullet chart - desired results
Best Answer
-
Try removing the SUM functions in your beast mode and then in your target value change the aggregation type to SUM. I played around with the different variations and I was able to duplicate your issue when I added the SUM functions within the beast mode. Taking them out and using the SUM function in the aggregation type took away the duplication on the x-axis.
**Check out my Domo Tips & Tricks Videos
**Make sure toany users posts that helped you.
**Please mark as accepted the ones who solved your issue.0
Answers
-
Is there anything in your Sorting properties? I'm wondering if LOB is in your Sorting properties and that is causing the x-axis to be repeated.
**Check out my Domo Tips & Tricks Videos
**Make sure toany users posts that helped you.
**Please mark as accepted the ones who solved your issue.0 -
There are currently no sorts being applied.
0 -
Try removing the SUM functions in your beast mode and then in your target value change the aggregation type to SUM. I played around with the different variations and I was able to duplicate your issue when I added the SUM functions within the beast mode. Taking them out and using the SUM function in the aggregation type took away the duplication on the x-axis.
**Check out my Domo Tips & Tricks Videos
**Make sure toany users posts that helped you.
**Please mark as accepted the ones who solved your issue.0 -
@MarkSnodgrass the suggestion you have provided worked. I moved the aggregation from beast mode to the ETL/dataflow (via Add Formula in the Group By) and the values are not split anymore! Much thanks for your help!
1 -
you generally shouldn't put an aggregate function inside a CASE statement.
the reason why your final solution works is b/c by using the aggregate functions in Analyzer, functionally you're moving the aggregate out of the CASE statement.
you could write your beast mode as:
sum( CASE WHEN `LOB` = 'WLS' and `L2` = 'INBOUND' THEN ... ... WHEN `LOB` = 'WLN' and `L2` = 'INBOUND' THEN ... END )
I always recommend writing the aggregation into the beast mode if appropriate because it forces people to use the metric 'the right way'.
ex. sometimes it's inappropriate to use AVG() or SUM() or MAX() so might as well build a beast mode for that.
Jae Wilson
Check out my 🎥 Domo Training YouTube Channel 👨💻
**Say "Thanks" by clicking the ❤️ in the post that helped you.
**Please mark the post that solves your problem by clicking on "Accept as Solution"0
Categories
- All Categories
- 2K Product Ideas
- 2K Ideas Exchange
- 1.6K Connect
- 1.3K Connectors
- 311 Workbench
- 6 Cloud Amplifier
- 9 Federated
- 3.8K Transform
- 656 Datasets
- 115 SQL DataFlows
- 2.2K Magic ETL
- 813 Beast Mode
- 3.3K Visualize
- 2.5K Charting
- 81 App Studio
- 45 Variables
- 771 Automate
- 190 Apps
- 481 APIs & Domo Developer
- 77 Workflows
- 23 Code Engine
- 36 AI and Machine Learning
- 19 AI Chat
- AI Playground
- AI Projects and Models
- 17 Jupyter Workspaces
- 410 Distribute
- 120 Domo Everywhere
- 280 Scheduled Reports
- 10 Software Integrations
- 142 Manage
- 138 Governance & Security
- 8 Domo Community Gallery
- 48 Product Releases
- 12 Domo University
- 5.4K Community Forums
- 41 Getting Started
- 31 Community Member Introductions
- 114 Community Announcements
- 4.8K Archive