How to get 2 decimal places only
Hi,
I am using a beast mode calculation that results in a ratio for forward to manager : hire
CONCAT(Sum(CASE WHEN To Step
= 'Forward to HM'THEN 1 ELSE 0 END)/(COUNT(DISTINCT Requisition Number
)) , ':', Sum(CASE WHEN To Step
= 'Hire'THEN 1 ELSE 0 END)/(COUNT(DISTINCT Requisition Number
)) )
The result is this:
How do I get it to say 4.89 : 1.43 I've tried a bunch of things, but I can't get rid of the extra decimal numbers. Any help is much appreciated.
Thanks,
Gunjan
Best Answer
-
Try:
CONCAT(ROUND(Sum(CASE WHEN `To Step` = 'Forward to HM' THEN 1 ELSE 0 END)/(COUNT(DISTINCT `Requisition Number`)),2), ':', ROUND(Sum(CASE WHEN `To Step` = 'Hire' THEN 1 ELSE 0 END)/(COUNT(DISTINCT `Requisition Number`)),2))
If I solved your problem, please select "yes" above
2
Answers
-
You can wrap each of the two parts of your concat with ROUND().
CONCAT(ROUND(Sum(CASE WHEN
To Step
= 'Forward to HM'THEN 1 ELSE 0 END)/(COUNT(DISTINCTRequisition Number
)),2) , ':', ROUND(Sum(CASE WHENTo Step
= 'Hire'THEN 1 ELSE 0 END)/(COUNT(DISTINCTRequisition Number
)),2) )If I solved your problem, please select "yes" above
1 -
Thanks @ColemenWilson there seems to be a syntax error. Not sure where.
0 -
Try:
CONCAT(ROUND(Sum(CASE WHEN `To Step` = 'Forward to HM' THEN 1 ELSE 0 END)/(COUNT(DISTINCT `Requisition Number`)),2), ':', ROUND(Sum(CASE WHEN `To Step` = 'Hire' THEN 1 ELSE 0 END)/(COUNT(DISTINCT `Requisition Number`)),2))
If I solved your problem, please select "yes" above
2 -
OMG yes it worked Yay! Thank you so much @ColemenWilson
0
Categories
- All Categories
- 1.5K Product Ideas
- 1.5K Ideas Exchange
- 1.4K Connect
- 1.1K Connectors
- 278 Workbench
- 4 Cloud Amplifier
- 4 Federated
- 2.7K Transform
- 89 SQL DataFlows
- 560 Datasets
- 2K Magic ETL
- 3.3K Visualize
- 2.3K Charting
- 575 Beast Mode
- 13 App Studio
- 28 Variables
- 582 Automate
- 141 Apps
- 414 APIs & Domo Developer
- 26 Workflows
- 1 DomoAI
- 28 Predict
- 12 Jupyter Workspaces
- 16 R & Python Tiles
- 356 Distribute
- 95 Domo Everywhere
- 259 Scheduled Reports
- 2 Software Integrations
- 92 Manage
- 89 Governance & Security
- 9 Product Release Questions
- Community Forums
- 42 Getting Started
- 28 Community Member Introductions
- 89 Community Announcements
- 4.8K Archive