If the resulting date has a day that is larger than the maximum day for the new month, the day is adjusted to the maximum days in the new month. : DATE_ADD : Date Time Functions MySQL TUTORIALS


MySQL TUTORIALS » Date Time Functions » DATE_ADD »

 

If the resulting date has a day that is larger than the maximum day for the new month, the day is adjusted to the maximum days in the new month.


mysql>
mysql> SELECT DATE_ADD('1998-01-30', INTERVAL MONTH);
+------------------------------------------+
| DATE_ADD('1998-01-30', INTERVAL MONTH|
+------------------------------------------+
1998-02-28                               |
+------------------------------------------+
row in set (0.00 sec)

mysql>



Leave a Comment / Note


 
Verification is used to prevent unwanted posts (spam). .

Follow Navioo On Twitter

MySQL TUTORIALS

 Navioo Date Time Functions
» DATE_ADD