Activiey after a certain time in a DateTime formatted column
I am trying to see activity completed after 5pm, regardless of the day. I am not sure how to even begin creating this type of beastmode (if necessary). My Last_updated_date column is in a datetime format. I need to see the date but either have items color coded if after 5pm or have or have a new column added with a some sort of flag that represents any time after 5pm in the datetime column. Seeing this in a table card would be ideal. Any assistance would be greatly appreciated.
Best Answer
-
There's a few ways you could accomplish this, and in the ways you mentioned. Be cognizant of time zone that can effect datetimes as well as functions available in beast modes to retrieve a time. The below will work well for a card using a table visualization:
Card level filter that filters on the date column, checking whether or not the time portion of the date is greater than 5pm. For instance, in a beast mode you can do this "CASE WHEN TIME(`Last_updated_date`) > TIME('17:00:00') THEN 1 ELSE 0 END". Then use this to filter for the "1" values and your card should be updated to only show those rows where last_updated_date is greater than 5pm.
You can go a step further and apply custom coloring to your tables, if you wanted, which Domo provides great samples on here: https://knowledge.domo.com/Visualize/Adding_Cards_to_Domo/KPI_Cards/Transforming_Data_Using_Beast_Mode/04Sample_Beast_Mode_Calculations
Just scroll down to the "Conditional Formatting for a Standard Table" section. This uses some HTML though if you're not familiar with that.
2
Answers
-
There's a few ways you could accomplish this, and in the ways you mentioned. Be cognizant of time zone that can effect datetimes as well as functions available in beast modes to retrieve a time. The below will work well for a card using a table visualization:
Card level filter that filters on the date column, checking whether or not the time portion of the date is greater than 5pm. For instance, in a beast mode you can do this "CASE WHEN TIME(`Last_updated_date`) > TIME('17:00:00') THEN 1 ELSE 0 END". Then use this to filter for the "1" values and your card should be updated to only show those rows where last_updated_date is greater than 5pm.
You can go a step further and apply custom coloring to your tables, if you wanted, which Domo provides great samples on here: https://knowledge.domo.com/Visualize/Adding_Cards_to_Domo/KPI_Cards/Transforming_Data_Using_Beast_Mode/04Sample_Beast_Mode_Calculations
Just scroll down to the "Conditional Formatting for a Standard Table" section. This uses some HTML though if you're not familiar with that.
2 -
Perfect. Thank you so much!
0
Categories
- 10.5K All Categories
- 8 Connect
- 918 Connectors
- 250 Workbench
- 470 Transform
- 1.7K Magic ETL
- 69 SQL DataFlows
- 477 Datasets
- 195 Visualize
- 253 Beast Mode
- 2.1K Charting
- 11 Variables
- 17 Automate
- 354 APIs & Domo Developer
- 89 Apps
- 3 Workflows
- 20 Predict
- 5 Jupyter Workspaces
- 15 R & Python Tiles
- 247 Distribute
- 63 Domo Everywhere
- 243 Scheduled Reports
- 21 Manage
- 42 Governance & Security
- 174 Product Ideas
- 1.2K Ideas Exchange
- 12 Community Forums
- 27 Getting Started
- 14 Community Member Introductions
- 55 Community News
- 4.5K Archive