How can it be possible to add 3 months interval in a MySQL date without using the word ‘Months’ with interval?


It is possible with the help of keyword Quarter as follows −

mysql> Select '2017-06-20' + INTERVAL 1 Quarter AS 'After 3 Months Interval';

+-------------------------+
| After 3 Months Interval |
+-------------------------+
| 2017-09-20              |
+-------------------------+
1 row in set (0.00 sec)

Updated on: 29-Jan-2020

246 Views

Kickstart Your Career

Get certified by completing the course

Get Started
Advertisements