Hi
I used the following code (similar to yours) . But my output is populating in the first entry for New date as blank and not bringing 2013 instead brings 0001 in dd.mm.yy and last field is also having a problem. Total no. of entries shouls be 365 but it shows 366 for one code XX2
DATA: L_CALDAY TYPE /BI0/OICALDAY,
WA_PACKAGE TYPE _ty_S_TG_1,
WA_PACK TYPE _ty_S_TG_1,
IT_PACKAGE TYPE STANDARD TABLE OF _ty_S_TG_1,
L_CONST TYPE RSARECORD.
IT_PACKAGE[] = RESULT_PACKAGE[].
L_CONST = 1.
LOOP AT IT_PACKAGE INTO WA_PACK.
L_CALDAY = WA_PACK-/BIC/NEWDATE.
IF SY-TABIX NE 1.
L_CONST = L_CONST + 1.
WA_PACK-RECORD = L_CONST.
MODIFY RESULT_PACKAGE FROM WA_PACK INDEX SY-TABIX.
ENDIF.
DO 365 TIMES.
L_CALDAY = L_CALDAY + 1.
L_CONST = L_CONST + 1.
WA_PACK-RECORD = L_CONST.
WA_PACK-/BIC/NEWDATE = L_CALDAY.
APPEND WA_PACK TO RESULT_PACKAGE.
ENDDO.
CLEAR : L_CALDAY.
ENDLOOP.
Output
Xx 2013 1 Xx2 7.3294
Xx 2013 02.01.0001 1 xx2 7.3294
Xx 2013 03.01.0001 1 xx2 7.3294
Until
.
.
Xx 2013 31.12.0001 1 xx2...
Xx 2013 01.01.0002 1 xx2....