I have a need to minus 6 hours from a time stamp if the current timestamp is greater than the current time.
I have attached the script for you to see.
Not sure what I'm doing wrong here.
Any help would be much appreciated.
SET validDate = realdate - 6 hour
where realdate > CURRENT_TIMESTAMP()