Jump to content

Date calculation on two variables


playaz

Recommended Posts

Hi guys,
I have a serious of forms on a site, basically when the form is created it puts the time in a field called 'created_date' in the DB (MySQL) similarly once the process is completed it puts the time in a field called 'completed_date'.

How can I calculate the time difference between the two columns within the row in the db?
e.g.
created-date - 2006-07-22 13:15:39
completed_date - 2006-07-25 14:24:35

How do I work out the difference between the two?

Thanks in advance :)
Link to comment
https://forums.phpfreaks.com/topic/15583-date-calculation-on-two-variables/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.