Unable to sum a beast mode formula
I'm trying to get the first and last days of the selected date range and return dollar amounts on those days.
When I use the following formula I am able to sum the dollars
CASE WHEN `InventoryDate` = '10/1/2022' THEN `dollarsOnHand` ELSE 0 END
When I use the following formula I lose the ability to sum the column
CASE WHEN `InventoryDate` = MIN(MIN(`InventoryDate`)) OVER (PARTITION BY `PartNum`) THEN `dollarsOnHand` ELSE 0 END
I thought maybe a null value was the culprit, so I tried wrapping the formula in ifnull and return a 0 if null, but that didn't work either. Any ideas why I would lose the ability a aggregate with the min min value instead of the actual date value?
Thanks for any help!!
Answers
-
There's no " over(partition by)" in BeastMode
I'm not a fixed function master, but I'm pretty sure you just need "BY". This user says FIXED BY is the same as ORDER(PARTITION BY)
Please 💡/💖/👍/😊 this post if you read it and found it helpful.
Please accept the answer if it solved your problem.
0 -
The fixed function looks pretty sweet. I converted my formula to this
CASE WHEN `InventoryDate` = MIN(MIN(`InventoryDate`)) FIXED (BY `PartNum`) THEN `dollarsOnHand` ELSE 0 END
But I still don't get an aggregate option to sum the column.
0
Categories
- All Categories
- 1.7K Product Ideas
- 1.7K Ideas Exchange
- 1.5K Connect
- 1.2K Connectors
- 295 Workbench
- 6 Cloud Amplifier
- 8 Federated
- 2.8K Transform
- 97 SQL DataFlows
- 608 Datasets
- 2.1K Magic ETL
- 3.8K Visualize
- 2.4K Charting
- 710 Beast Mode
- 49 App Studio
- 39 Variables
- 668 Automate
- 170 Apps
- 446 APIs & Domo Developer
- 45 Workflows
- 7 DomoAI
- 33 Predict
- 13 Jupyter Workspaces
- 20 R & Python Tiles
- 391 Distribute
- 111 Domo Everywhere
- 274 Scheduled Reports
- 6 Software Integrations
- 115 Manage
- 112 Governance & Security
- Domo Community Gallery
- 31 Product Releases
- 9 Domo University
- 5.3K Community Forums
- 40 Getting Started
- 30 Community Member Introductions
- 103 Community Announcements
- 4.8K Archive