Forum Discussion

quikin5's avatar
quikin5
Frequent Visitor
6 years ago
Solved

Generate a boolean column ifor the last hour

Hi, I have this streaming dataset (Assume current time is 10:50:00 AM) Time Values Last hour 09:42:13 AM 1 No 10:24:56 AM -1 Yes How can I generate the last column? This dataset i...
  • Anonymous's avatar
    Anonymous
    6 years ago

    Hi quikin5 ,

     

    Please try to use the below-calculated column, and it works on my desktop and you don't need to worry about the midnight issue I think.

     

    Last Hour = IF(HOUR(Your_Time_Column + 1/24) = HOUR(NOW()),"Yes","No") 

     

    Thanks.

    Aiolos Zhao