185
MySQL DATEDIFF() Function
The datediff() is a MySQL date/time function. It is used to get the difference between two date values.
Syntax
Parameter:
date1 & date2 : date’s for calculating the difference.
Returns
This function returns the difference in days between two date values.
Example 1
Output:
Example 2
Output:
Next TopicMySQL date/time