I have an application [iphone] that is sent to the server several times [using json], so the time looks like hh: mm 24-hour format, the time is saved in db as varchar.
I need to calculate elapsed time = endTime - startTime
but my problem is that I have time in db as varchar !, no timestamp,
- so how to calculate elapsed time without changing the type of the varchar field in my db ?, can I convert this hh: mm to int? for operation ?, and then showing it again as hh: mm, perhaps to save it in another table?
Many thanks!
source
share