I am creating an Oracle fast formula, I need to check the time between 06:00 AM and 12:00 AM i.e. when the PAY_TIME > 06:00 AM and less than 12:00 AM.
I am using the following -
L_STARTmin = TO_CHAR(AISTOPTIME, 'HH24:MI:SS')
But when I am comparing this to > 06:00:00 the condition is not entering the loop, I am using -
IF TO_DATE(L_STARTmin,'HH24:MI:SS')>= TO_DATE('06:00:00', 'HH24:MI:SS')AND TO_DATE(L_STOPmin,'HH24:MI:SS')<= TO_DATE('12:00:00', 'HH24:MI:SS')
How can i only compare the date part i.e. if time is 05:00:00 AM then this loop shouldnt be entered, else it should be, how to use the timestamp for this ?