I'm have a startDate and a endDate stored in a SQLite database and need to calculate the difference in minutes and seconds between the 2 datetimes using javascript.

For example: 

```
startDate = 2012-10-07 11:01:13
endDate = 2012-10-07 12:42:13

```

I've had a good read though loads of similar questions on SO but could only find things relating to calculating this as part of a select.