mysql - Difference between two datetime entries -


select eta,sta `schedule` `num`="5567"; 

2013-08-26 18:37:00 2013-08-26 18:30:00

select datediff(eta,sta) `schedule` `num`="5567"; 

0

why result 0 instead of 7 (i.e. minutes)?

datediff give result in days.

select hour (eta - sta) `schedule` `num`="5567"; 

an alternative hour difference.


Comments

Popular posts from this blog

java - activate/deactivate sonar maven plugin by profile? -

python - TypeError: can only concatenate tuple (not "float") to tuple -

java - What is the difference between String. and String.this. ? -