Fixed Function At Two Levels (Or nested Fixed Function)

I have a data set that includes duplicate rows for products.
I'm using a fixed function to de-dupe an aggregate sum of product prices because I only want one product row to contribute to the total.
The fixed function (total_product_price) looks like this: SUM(DISTINCT Price) FIXED (BY Product ID)
However, now I need to create a table that looks like this:
Store | Total Product Price | Total Price | Percent of Total |
---|---|---|---|
A | 100 | 300 | 0.33 |
B | 100 | 300 | 0.33 |
C | 100 | 300 | 0.33 |
The challenge is that the Total Price calculation must be a sum of the total_product_price calculation that is fixed to the entire data set (including the de-duplication in total_product_price performed by the Fixed Function).
Thank you in advance!
Best Answer
-
Have you tried using nested beastmodes? You may need to have nested beastmodes enabled by your CSM from Domo. You could try SUM(DISTINCT Price) FIXED (BY Product ID) as Beastmode 1 and then:
SUM(SUM(`Beastmode 1`) FIXED ())
If I solved your problem, please select "yes" above
0
Answers
-
Is ETL out of the question?
If I solved your problem, please select "yes" above
0 -
@ColemenWilson , it is the plan right now, to group the values and de-dupe there, but that will lock us into a those set aggregation fields and prevent responsive filters.
After hacking, I wasn't able to get the fixed function to work as we'd like.0 -
Have you tried using nested beastmodes? You may need to have nested beastmodes enabled by your CSM from Domo. You could try SUM(DISTINCT Price) FIXED (BY Product ID) as Beastmode 1 and then:
SUM(SUM(`Beastmode 1`) FIXED ())
If I solved your problem, please select "yes" above
0 -
@ColemenWilson - I will try this. It's actually what I thought of as I typed out the OP.
Thanks, I'll follow up if it works!0
Categories
- All Categories
- Product Ideas
- 2.1K Ideas Exchange
- Connect
- 1.3K Connectors
- 309 Workbench
- 7 Cloud Amplifier
- 10 Federated
- Transform
- 665 Datasets
- 120 SQL DataFlows
- 2.3K Magic ETL
- 825 Beast Mode
- Visualize
- 2.6K Charting
- 90 App Studio
- 46 Variables
- Automate
- 197 Apps
- 489 APIs & Domo Developer
- 94 Workflows
- 24 Code Engine
- AI and Machine Learning
- 23 AI Chat
- 4 AI Projects and Models
- 18 Jupyter Workspaces
- Distribute
- 119 Domo Everywhere
- 283 Scheduled Reports
- 11 Software Integrations
- Manage
- 145 Governance & Security
- 12 Domo Community Gallery
- 49 Product Releases
- 13 Domo University
- Community Forums
- 41 Getting Started
- 31 Community Member Introductions
- 116 Community Announcements
- 5K Archive