If this is your first visit, be sure to check out the FAQ by clicking the link above.
You may have to register before you can post: click the register link above to proceed.
To start viewing messages, select the forum that you want to visit from the selection below.
How can I subtract two datestamps (yyyy-mm-dd hh:mm:ss) to give the result in hours?
You can convert both times to seconds using unix_timestamp. Then subtract one from other to get number of seconds between both times. Then divide by 3600 to get the number of hours ie
You can convert both times to seconds using unix_timestamp. Then subtract one from other to get number of seconds between both times. Then divide by 3600 to get the number of hours ie