if have following expression:
IF([DateTime] <= "15:00","true","false")
in table there are following entries (DateTime - european timeformat):
31.01.2022 05:16 (AM)
30.01.2022 14:36
30.01.2022 15:00
30.01.2022 15:36
the result of if-expression is always "false"
31.01.2022 05:16 >>> result: "false"
30.01.2022 14:36 >>> result: "false"
30.01.2022 15:00 >>> result: "false"
30.01.2022 15:36 >>> result: "false"
Question: how do i have to modify "if-expression" to get correct results:
expression: IF([DateTime] <= "???????","true","false")
(AM) 31.01.2022 05:16 >>> result: "true"
(PM) 30.01.2022 14:36 >>> result: "true"
(PM) 30.01.2022 15:00 >>> result: "true"
(PM) 30.01.2022 15:36 >>> result: "false"
many thanks in advance for any help!
Solved! Go to Solution.
Please try with
IF(TIME([DateTime]) <= "15:00","true","false")
You can even simplify further as just
TIME([DateTime] <= "15:00")
The above comparison will anyway give you TRUE or FALSE result, so further IF() statement is not necessary. Using IF() is like IF( "Result TRUE", TRUE, FALSE)
Please try with
IF(TIME([DateTime]) <= "15:00","true","false")
You can even simplify further as just
TIME([DateTime] <= "15:00")
The above comparison will anyway give you TRUE or FALSE result, so further IF() statement is not necessary. Using IF() is like IF( "Result TRUE", TRUE, FALSE)
hello Suvrutt_Gurjar,
works perfect - thank you so much !!!
User | Count |
---|---|
34 | |
31 | |
30 | |
18 | |
17 |