Beast Mode formula: not calculating/populating

Hi - i created several Beast Mode formulas (TQ, LQ, QoQ). I have no issues adding TQ and LQ to a Pivot Table chart. When I add QoQ beast mode to the Pivot Table, no values are populated.
The QoQ formula is a difference of TQ and LQ. I can add TQ to TQ, or LQ to LQ and get a result. I just don't get a result if I mix TQ and LQ.
Is it a Domo performance issue? Eventually I want to divide the difference with LQ. What do you think the issue is?
Thanks in advance!
Beast Mode formula:
--2_Quarters_ago
((CASE WHEN (QUARTER(CURDATE())=1) THEN (CASE WHEN ((year(`Quarter`)=(year(CURDATE()) - 1)) AND (QUARTER(`Quarter`)=3)) THEN `Value` END )
ELSE (CASE WHEN ((year(`Quarter`)=year(CURDATE())) AND (QUARTER(`Quarter`)=(QUARTER(CURDATE()) -1))) THEN `Value` END ) END) -
--LastQuarter
(CASE WHEN (QUARTER(CURDATE())=1) THEN (CASE WHEN ((year(`Quarter`)=(year(CURDATE()) - 1)) AND (QUARTER(`Quarter`)=4)) THEN `Value` END )
ELSE (CASE WHEN ((year(`Quarter`)=year(CURDATE())) AND (QUARTER(`Quarter`)=(QUARTER(CURDATE()) -1))) THEN `Value` END ) END) )
Comments
-
I noticed some of your case statements don't have an ELSE clause. I would start by adding ELSE 0 to those as Domo doesn't like subtracting when one value is blank.
Hope this helps.
**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 -
Hi Mark - I added else 0 in the following places found in the below code. Seems like it's subtracting the TQ and LQ. But now the LQ formula is not displaying any values (even though that beast mode is independent of the QoQ one.
--2_Quarters_ago
((CASE WHEN (QUARTER(CURDATE())=1) THEN (CASE WHEN ((year(`Quarter`)=(year(CURDATE()) - 1)) AND (QUARTER(`Quarter`)=3)) THEN else 0 `Value` END )
ELSE (CASE WHEN ((year(`Quarter`)=year(CURDATE())) AND (QUARTER(`Quarter`)=(QUARTER(CURDATE()) -1))) THEN `Value` else 0 END ) END) -
--LastQuarter
(CASE WHEN (QUARTER(CURDATE())=1) THEN (CASE WHEN ((year(`Quarter`)=(year(CURDATE()) - 1)) AND (QUARTER(`Quarter`)=4)) THEN `Value` else 0 END )
ELSE (CASE WHEN ((year(`Quarter`)=year(CURDATE())) AND (QUARTER(`Quarter`)=(QUARTER(CURDATE()) -1))) THEN `Value` else 0 END ) END) )
0 -
@DomoNewbie perhaps its not finding the right timeframe. I would make a new beastmode to double check that Quarter(curdate) and all the other dates are actually returning what you are looking for. I would also double check if you have fiscal calendar enabled or not.
**If this answer solved your problem be sure to like it and accept it as a 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