SAP ABAP programming the last day of the month, the first day of or.
DATA: FIR_DATA TYPE SY-DATUM. "the first day
DATA: LAS_DATA TYPE SY-DATUM. "the last day.
FIR_DATA = SY-DATUM.
LAS_DATA = SY-DATUM.
FIR_DATA+6 (2) = '288. "make the current date 28.
LAS_DATA = LAS_DATA + 5. "the maximum number of days in a month is 31 days, and after + 5, it must be the first day of next month.
LAS_DATA+6 (2) = '01mm. "the first day of next month
LAS_DATA = LAS_DATA-1. "the last day of the month
WRITE: SY-DATUM,FIR_DATA,LAS_DATA.
* * in the end, you can find the first or last day of any month.