10-03-2011 5:05 AM
Hi,
I am getting a SUM_OVERFLOW DUMP when running a report in summerised List, while its running correctly in Detailed List.
The field I am using for Total is TYPE bsik-dmbtr.
Runtime Errors SUM_OVERFLOW
Except. CX_SY_ARITHMETIC_OVERFLOW
Any solution?
10-03-2011 5:36 AM
Hi,
If you are using function module REUSE_ALV_GRID_DISPLAY or REUSE_ALV_LIST_DISPLAY, are you making use of the export parameter I_CALLBACK_USER_COMMAND ?
If yes, there is some problem in this subroutine. Put a break point and check.
Regards,
Danish.
10-03-2011 5:24 AM
10-03-2011 5:29 AM
10-03-2011 5:30 AM
10-03-2011 5:36 AM
Hi,
If you are using function module REUSE_ALV_GRID_DISPLAY or REUSE_ALV_LIST_DISPLAY, are you making use of the export parameter I_CALLBACK_USER_COMMAND ?
If yes, there is some problem in this subroutine. Put a break point and check.
Regards,
Danish.
10-03-2011 5:44 AM
Hi,
Yes I m using i_callback_user_command but on setting up the breakpoints it is not showing anything just showing the dump
FORM start_list_viewer_item.
DATA: pgm LIKE sy-repid.
pgm = sy-repid.
CALL FUNCTION 'REUSE_ALV_LIST_DISPLAY'
EXPORTING
i_callback_program = pgm
i_callback_user_command = 'USER_COMMAND1'
it_fieldcat = fieldcat1
it_sort = sortcat1
is_layout = layout_in1
i_save = 'A'
it_events = eventcat1
TABLES
t_outtab = t_line
EXCEPTIONS
OTHERS = 2.
ENDFORM. " START_LIST_VIEWER_item
Total Number when i run detailed list is displayed as 35,608,528.31 and 35,964,566.00-
10-03-2011 5:45 AM
The Number when i run detailed list is displayed as 35,608,528.31 and 35,964,566.00-
10-03-2011 5:48 AM
Hi ,
The field DMBTR is having domain WERT7. Try using field or type with domain WERT9 and if you still get same error you can go for even more lenght of domain. just check in SE11 for different options of domain with WERT*.
Regards,
Ganesh.
10-03-2011 7:28 AM
Hi,
please help me out in getting the field or type with domain WERT9.
10-03-2011 7:40 AM
Hi,
Why you want field name?
go to WERT9 domain, press where used list button it will give you list of data elements.
You can declare total type <Data element ANY OF BELOW>.
DMHAB_LONG
DMSOL_LONG
ESBTR_EB
ESDMB_EB
FB_ICRC_ADIFF
FB_ICRC_DFOSP
FB_ICRC_DLOPP
FB_ICRC_DPREV
FC_ADDCO
FC_BKVAL
FC_COGMT
FC_HSL_C
FC_HSL_D
FC_KSL_C
FC_KSL_D
FC_LCVALIE
FC_NV2LC
FC_NV3LC
FC_VLC_EQ
FC_VLC_INV
FC_VRC_INV
ICRC_DAMNT
ICRC_GDIFF
ICRC_PAMNT
ICRC_TAMNT
ICRC_TDIFF
J_1IADDVAL
J_3RFBPR1
J_3RFBSM
J_3RFDELTAPRICE
J_3RFESM
J_3RFINSUM
J_3RFINSUMDOC
J_3RFISSVAL
10-03-2011 7:45 AM
10-03-2011 8:30 AM
10-03-2011 9:28 AM
Hi,
Are you using the SUM operation?
If yes, this statement tries to subtotal ALL the numeric fields of your table... The exception can be raised for another field that the one you changed... Please check them all.
Kr,
m.
10-03-2011 9:31 AM
Hi,
Please paste the code of the field catalog of that column on which you want to provide summation.
Regards,
Danish.
10-03-2011 9:32 AM
10-03-2011 9:50 AM
I have changed the field to TYPE P Decimals 2 but It not resolved showing the same dump
It showing correctly for 5 or 6 lifnr, but when i tried to get large data it's throwing the SUM OVERFLOW Dump
Here's the code for field catalog
FORM write_list .
DATA :
tot TYPE p DECIMALS 2,
tot1 TYPE p DECIMALS 2,
tot2 TYPE p DECIMALS 2,
tot3 TYPE p DECIMALS 2,
tot4 TYPE p DECIMALS 2,
tot5 TYPE p DECIMALS 2,
tot6 TYPE p DECIMALS 2,
tot7 TYPE p DECIMALS 2,
totn TYPE p DECIMALS 2,
totn6 TYPE p DECIMALS 2,
totn66 TYPE p DECIMALS 2,
name1(40).
DATA : BEGIN OF name OCCURS 100,
lifnr LIKE lfa1-lifnr,
name1 LIKE lfa1-name1,
END OF name.
DELETE itab WHERE total = 0.
SORT itab BY lifnr.
SELECT lifnr name1 FROM lfa1 INTO TABLE name
FOR ALL ENTRIES IN itab
WHERE lifnr = itab-lifnr.
DELETE ADJACENT DUPLICATES FROM name COMPARING lifnr name1.
LOOP AT itab.
AT NEW lifnr.
READ TABLE name WITH KEY lifnr = itab-lifnr.
IF sy-subrc = 0.
itab-name1 = name-name1.
MODIFY itab TRANSPORTING name1.
ENDIF.
SUM.
WRITE 😕 itab-lifnr NO-GAP, sy-vline NO-GAP,
(35) itab-name1 NO-GAP, sy-vline NO-GAP,
(20) itab-total NO-GAP, sy-vline NO-GAP ,
(20) itab-notdue NO-GAP, sy-vline NO-GAP ,
(20) itab-notdue6 NO-GAP, sy-vline NO-GAP ,
(20) itab-notdue66 NO-GAP, sy-vline NO-GAP ,
(20) itab-age2 NO-GAP, sy-vline NO-GAP,
(20) itab-age3 NO-GAP, sy-vline NO-GAP,
(20) itab-age4 NO-GAP, sy-vline NO-GAP,
(20) itab-age5 NO-GAP, sy-vline NO-GAP,
(20) itab-agen NO-GAP, sy-vline NO-GAP,
(20) itab-agel NO-GAP, sy-vline NO-GAP.
tot = itab-total + tot.
tot1 = itab-age2 + tot1. tot2 = itab-age3 + tot2.
tot3 = itab-age4 + tot3. tot4 = itab-age5 + tot4.
tot5 = itab-agen + tot5.
tot6 = itab-agel + tot6.
totn = itab-notdue + totn . totn6 = itab-notdue6 + totn6. totn66 = itab-notdue66 + totn66.
ENDAT.
ENDLOOP.
WRITE :/(270) sy-uline NO-GAP,(270) sy-uline.
WRITE :/47 sy-vline,(19) tot NO-GAP COLOR COL_TOTAL, sy-vline NO-GAP,
(19) totn COLOR COL_TOTAL, sy-vline NO-GAP,
(19) totn6 COLOR COL_TOTAL, sy-vline NO-GAP,
(19) totn66 COLOR COL_TOTAL, sy-vline NO-GAP,
(19) tot1 COLOR COL_TOTAL, sy-vline NO-GAP,
(19) tot2 COLOR COL_TOTAL, sy-vline NO-GAP,
(19) tot3 COLOR COL_TOTAL, sy-vline NO-GAP,
(19) tot4 COLOR COL_TOTAL, sy-vline NO-GAP,
(19) tot5 COLOR COL_TOTAL, sy-vline NO-GAP,
(19) tot6 COLOR COL_TOTAL, sy-vline NO-GAP.
ULINE /47(240).
ENDFORM. " WRITE_LIST
10-03-2011 9:58 AM
Hi Nishant ,
You might be using "Sum " statement in your COde :
This SUM will work fine only when it is of type I,F, or P type fields . OTherwise it will give problem in calculation .
SO you have to change type of fields which you have used .
regards
Deepak.
10-03-2011 10:07 AM
SUM Statement is used, I have tried using TYPE P Decimals 2, but no success
While using type C it still not working.
It showing correctly for 5 or 6 lifnr, but when i tried to get large data it's throwing the SUM OVERFLOW Dump
10-03-2011 10:23 AM
Hi Nishant ,
Actually there is no problem in your Code ,
When you are Executing SUM statement .
What it does is It creates work area to store values on sum , and That sum values Goes Beyond length of field
And it cannot store that value so it gives dump .
Better Try to Increase Length of that Field which stores large Value .
Regards
Deepak.
10-03-2011 10:33 AM
Hi,
The problem is in the declaration part of your itab.
Please paste that part over here...
Kr,
m.
10-03-2011 10:43 AM
Hi Nishant ,
Check this Field Type AMOUNT_KK .
Change your Field Type with this AMOUNT_KK data Element and Execute report .
regards
Deepak.
10-03-2011 11:02 AM
here's the itab code
BEGIN OF itab OCCURS 1000,
lifnr LIKE lfa1-lifnr,
bukrs LIKE bsik-bukrs,
belnr LIKE bsik-belnr,
bldat LIKE bsik-bldat,
xblnr LIKE bsik-xblnr,
zuonr LIKE bsik-zuonr,
sgtxt LIKE bsik-sgtxt,
wrbtr LIKE bsik-wrbtr,
budat LIKE bsik-budat,
waers LIKE bsik-waers,
blart LIKE bsik-blart,
dmbtr LIKE bsik-dmbtr,
zfbdt LIKE bsik-zfbdt,
zterm LIKE bsik-zterm,
bschl LIKE bsik-bschl,
total LIKE bsik-dmbtr,
zfuture LIKE bsik-dmbtr,
zcurrent LIKE bsik-dmbtr,
crbal LIKE bsik-dmbtr,
30days LIKE bsik-dmbtr,
60days LIKE bsik-dmbtr,
90days LIKE bsik-dmbtr,
99days LIKE bsik-dmbtr,
120days LIKE bsik-dmbtr,
180days LIKE bsik-dmbtr,
365days LIKE bsik-dmbtr,
age(10) TYPE c, "p
age2 TYPE p DECIMALS 2 ,
age3 TYPE p DECIMALS 2 ,
age4 TYPE p DECIMALS 2 ,
age5 TYPE p DECIMALS 2 ,
age6 TYPE p DECIMALS 2 ,
agen TYPE p DECIMALS 2 ,
agel TYPE p DECIMALS 2 ,
l_age2 TYPE p DECIMALS 2 ,
l_age3 TYPE p DECIMALS 2 ,
l_age4 TYPE p DECIMALS 2 ,
l_age5 TYPE p DECIMALS 2 ,
l_agen TYPE p DECIMALS 2 ,
l_agel TYPE p DECIMALS 2 ,
erdat LIKE lfa1-erdat,
name1 LIKE lfa1-name1,
name2 LIKE lfa1-name2,
stras LIKE lfa1-stras,
ort01 LIKE lfa1-ort01,
ktokk LIKE lfa1-ktokk,
hkont LIKE bsik-hkont,
psort(10),
totsal LIKE bsik-dmbtr,
zbd1t LIKE bsik-zbd1t,
zbd2t LIKE bsik-zbd2t,
zbd3t LIKE bsik-zbd3t,
shkzg LIKE bsik-shkzg,
umskz LIKE bsik-umskz,
doc_days(10) TYPE c,
faedt LIKE vtopis-hdatum,
days(8) TYPE c,
notdue LIKE bsik-dmbtr,
notdue6 LIKE bsik-dmbtr,
notdue66 LIKE bsik-dmbtr,
END OF itab.
10-03-2011 11:10 AM
Hi ,
Change your TOTAL field type
TOTAL type TFM_AMOUNT .
so you want curr type with more length
find in SE15->abap dictionary -> data lement -> give length and data type = CURR
regards
Deepak.
10-03-2011 11:18 AM
Hi,
Could you try by replacing all those LIKE bsik-dmbtr with TYPE J_3RFINSUM ?
Kr,
m.
10-03-2011 11:43 AM
Hi,
I have tried all permutation and combinations as stated here, but nothing seems like working
Regards,
Nishant
10-03-2011 12:42 PM
Check in your dump (Error analysis section): On which field is the exception triggered?
As suggested by Deepak, try changing them all again with TYPE TFM_AMOUNT...
If it stil not working, I'm afraid only the type F will be ok... you seem to have really huge values to play with...
Kr,
m.
Edited by: Manu D'Haeyer on Oct 3, 2011 1:50 PM
10-03-2011 3:31 PM
It looks like you haven't taken care of the debits and credits, so it is taking all amounts as positive. Correct that and you should be OK.
Rob
10-03-2011 9:56 AM
10-04-2011 4:17 AM
Thanks all of you for your reply,
I got it solved, there is problem with a zbd1t is of type DEC 3 i made it
zbd1t TYPE FI_DAYS_ALV (DEC08)
Got it solved thanks once again.
Regards,
Nishant
10-04-2011 4:18 AM