/ Published in: SQL
This will return the number of seconds between now and when the time field was inserted.
Expand |
Embed | Plain Text
Copy this code and paste it in your HTML
SELECT unix_timestamp(CURRENT_TIMESTAMP) - unix_timestamp(time_field) AS timediff FROM TABLE_NAME;