Forum Discussion
SHAKEDALROY
5 years agoHelper I
Day time Night time
Hi, I'm fairly new to Power BI and I'm not sure if this functionality is even avaliable but what I'm trying to do is creating a new conditional column based on a time type column "IssueTime" (08...
- 5 years ago
Fowmy
5 years agoSuper User
SHAKEDALROY
Add this as a custom column please:
=if [Issue Time] >= #time(6,0,0) and [Issue Time] <= #time(19,59,59) then "Day Time" else if
[Issue Time] >= #time(20,0,0) and [Issue Time] <= #time(23,59,59) then "Night time" else if
[Issue Time] >= #time(0,0,0) and [Issue Time] <= #time(5,59,59) then "Night time" else null________________________
If my answer was helpful, please click Accept it as the solution to help other members find it useful
Click on the Thumbs-Up icon if you like this reply 🙂
- SHAKEDALROY5 years agoHelper I
Thank you very much for your help! Fowmy 😁
- Fowmy5 years agoSuper User
- Krati_rastogi3 years agoNew Member
Tried to run that code but unable to make it.