mysql previous quarter


SET @PERIOD_END_DT = '201509';
SELECT date_format(date_add(CONCAT(@PERIOD_END_DT,'01'),interval -1 quarter),'%Y%m')

댓글