Replace Undefined/Blank with a value in Beast Mode
Hi,
I am calculating accuracy with a formula inside Beast Mode:
(A  F) / A * 100.
There are few instances where the denominator is 0.
For those instances, I am getting blank values as shown below:
I want to replace the blank/undefined with a different value
I tried to use the CASE and IFNULL BeastMode functions but that did not work.
Can someone help me with this?
Thanks,
Prajwal
Best Answer

Here's what I've done in the past that has worked. Call out the denominator as zero calulcation first, then go on to the calculation if it's fine.
CASE
WHEN IFNULL(SUM(`AdjustedSalesRevenue),0) = 0 THEN 0
ELSE
[calculation]
END
Does something like that work for you?
Aaron
MajorDomo @ Merit Medical
**Say "Thanks" by clicking the heart in the post that helped you.
**Please mark the post that solves your problem by clicking on "Accept as Solution"0
Answers

Here's what I've done in the past that has worked. Call out the denominator as zero calulcation first, then go on to the calculation if it's fine.
CASE
WHEN IFNULL(SUM(`AdjustedSalesRevenue),0) = 0 THEN 0
ELSE
[calculation]
END
Does something like that work for you?
Aaron
MajorDomo @ Merit Medical
**Say "Thanks" by clicking the heart in the post that helped you.
**Please mark the post that solves your problem by clicking on "Accept as Solution"0 
This works.Thanks.
Prajwal
0
Categories
 All Categories
 1.7K Product Ideas
 1.7K Ideas Exchange
 1.5K Connect
 1.2K Connectors
 292 Workbench
 4 Cloud Amplifier
 8 Federated
 2.8K Transform
 95 SQL DataFlows
 600 Datasets
 2.1K Magic ETL
 3.7K Visualize
 2.4K Charting
 685 Beast Mode
 43 App Studio
 38 Variables
 656 Automate
 170 Apps
 439 APIs & Domo Developer
 42 Workflows
 5 DomoAI
 32 Predict
 12 Jupyter Workspaces
 20 R & Python Tiles
 384 Distribute
 110 Domo Everywhere
 268 Scheduled Reports
 6 Software Integrations
 111 Manage
 108 Governance & Security
 8 Domo University
 25 Product Releases
 Community Forums
 39 Getting Started
 29 Community Member Introductions
 98 Community Announcements
 Domo Community Gallery
 4.8K Archive