Short dump when I do total or sub total in the ALV report
Hi,
When I do total or sub-total on the currency field in the ALV report, it'll give a short dump like
" The current application program detected a situation which really
should not occur. Therefore, a termination with a short dump was
triggered on purpose by the key word MESSAGE (type X)".
Short text of error message:
Technical information about the message:
Message classe...... "0K"
Number.............. 000
Variable 1.......... " "
Variable 2.......... " "
Variable 3.......... " "
Variable 4.......... " "
Variable 3.......... " "
Variable 4.......... " "
Trigger Location of Runtime Error
Program SAPLSLVC
Include LSLVCF36
Row 2,726
Module type (FORM)
Module Name FILL_DATA_TABLE
sometime when I do the page down on the ALV report, the same short dump is coming.
Can anyone help me out.
Thanks
Selva
Hi,
I'm getting this short dump in the standard program.
I'm getting ALV report display perfectly. the problem is, when I do total or subtotal on the currency fields.
2704
2705 ************************************
2706 * Column per Fieldcat Entry
2707 ************************************
2708 ls_lvc_data-value = space.
2709 clear ls_lvc_data-style.
2710 loop at it_fcat_local assigning <ls_fcat>
2711 where tech ne 'X' and no_out ne 'X'.
2712 if l_invisible eq 'X'.
2713 clear l_invisible.
2714 if <ls_fcat>-do_sum is initial.
2715 continue.
2716 else.
2717 clear ls_lvc_data-col_pos.
2718 endif.
2719 endif.
2720
2721 add 1 to ls_lvc_data-col_pos.
2722
2723 assign component <ls_fcat>-fieldname
2724 of structure <ls_data> to <l_field_value>.
2725 if sy-subrc ne 0.
>>>>> message x000(0k).
2727 endif.
2728
in this standard program, I'm getting the dump. the line is mentioned above in the code.
Similar Messages
-
Short Dump when the Bex-Report scheduled for Broadcast
Hi Guru's
I am getting the short dump when I am scheduling the Bex-Report for Broadcasting. Need your help to reslove this issue.
Thanks
Navin
Note
The following error text was processed in the system BDV : The current application triggered a termination with a short dump.
The error occurred on the application server spdbwd01_BDV_05 and in the work process 0 .
The termination type was: RABAX_STATE
The ABAP call stack was:
Form: INTERNAL_ERROR of program SAPLSDCL
Form: PHIO_GET_CONTENT_ACCESS of program SAPLSDCI
Function: SDOK_PHIO_GET_CONTENT_ACCESS of program SAPLSDCI
Function: SKWF_PHIO_CONTENT_ACCESS_GET of program SAPLSKWF_CONTENT
Method: COPY_MIME_TO_FOLDER of program CL_RSRA_KWF_UTILITIES=========CP
Method: GET_STYLESHEET of program CL_RSRA_KWF_TMPL==============CP
Method: CONSTRUCTOR of program CL_RSRA_KWF_TMPL==============CP
Method: SET_TEMPLATE_FOLDER of program CL_RSRA_ENGINE_BC=============CP
Method: CONSTRUCTOR of program CL_RSRA_ENGINE_BC=============CP
Method: EXECUTE_SINGLE of program CL_RSRA_JOB===================CPHI Navin,
Check the short dump analysis in T-code ST22.
and also check the Information Broadcast Settings / Configuration
Check the error for Emails in t-code SCOT. BASIS Consultants will help you on this issue.
Regards
Daya Sagar -
Facing short dumps when trying to open session in CSA
Hi
All am facing Short dump when i am trying to open session in CSA
Error detials:
go to System Administration workcenter task management up CSA. Choose the Solution
got short dump:
Short text
Length error occurred in IMPORT statement.
What happened?
Error in the ABAP Application Program
The current ABAP program "SAPLDSVAS_PROC" had to be terminated because it has
come across a statement that unfortunately cannot be executed.
Error analysis
An exception occurred that is explained in detail below.
The exception, which is assigned to class 'CX_SY_IMPORT_MISMATCH_ERROR', was
not caught in
procedure "LOAD" "(METHOD)", nor was it propagated by a RAISING clause.
Since the caller of the procedure could not have anticipated that the
exception would occur, the current program is terminated.
The reason for the exception is:
During import the system discovered that the target object has
a different length than the object to be imported.
Missing RAISING Clause in Interface
Program SAPLDSVAS_PROC
Include LDSVAS_PROCTAI
Row 1.431
Module type (METHOD)
Module Name LOAD
Trigger Location of Exception
Program SAPLDSVAS_PROC
Include LDSVAS_PROCTAI
Row 1.514
Module type (METHOD)
Module Name LOAD
Please help me to solve this problem
Regards,
NeniHello Neni
According to the information I saw in that post it could be caused by a sort of inconsistency of the program code vs a structure.
Wether that is a bug that is in your SAP Solution Manager release or something that is caused by administrative actions (perhaps solving SPAU entries after SP stack update or upgrade) I cannot tell.
I would recommend you either try and find a relative SAP note (narrowing down result to only your SAP Solution Manager system) and searching using the dump keywords. If you cannot find anything I would recommend you to open a customer message so SAP can take a look at the specific error.
If you give more information, perhaps someone on the forum can help you out abit better, which SAP Solution Manager version and so on.
You also didn't answer my question, any recent changes you are aware of ?
Kind regards
Tom -
Short Dump when trying to open C-project due to status
Hi,
We have a daily batch job in CRM that reports all the project ID's and
sends e-mails out to recipients.
As part of this report it retrieves the statuses for the project ID's,
however the report short dumps when retrieving the status for one of
the projects because it is not finding an active status.
When we try and open the project in C-projects we get the same short
dump error: CX_DPR_FATAL_ERROR so we cannot view or update the status.
When we investigate this issue we find that in table CRM_JCDS there are
3 entries for this project ID. One of the statuses is inactive (I1703)
but there is another status that is active (I1701). The two status
entries were created at exactly the same date and time and by the same
user.
In table CRM_JEST there is only one entry shown which shows an inactive
status and we believe this to be the wrong status. Please can you
advise if this status conflict is causing the problem and also how to
resolve this issue?Hi Paul,
generally, the project and its elements must have an active status in table CRM_JEST, however, at this point it is not clear how this inconsistency arised. There is no SAP standard report or a 'generally valid' solution that could solve this issue, however, I found a customer message that you have opened in September with exactly the same problem. A colleague from the development team already provided you with a correction report, but there was no feedback from your side if it helped or not.
It is very difficult to provide help as inconsistencies can have several different causes, so the best would be to have this checked in a customer message with an example.
Regards,
Silvia -
GETWA_NOT_ASSIGNED short dump when load business partner master data
Hi
I've this error GETWA_NOT_ASSIGNED short dump when load business partner master data, it's running in BI 7.0 with support package 12.
The error is because the field symbol is that pointed to the line of an internal table that was deleted.
I think that it's an incompatibility between subroutine and unicode.
Do you have idea about correct this error?
Regards
Jose.Hi Ravi
Yes, it's a dump
It's when running a process chain to load Business partner master data
The error say:
-.You address a field symbol that pointed to the line of an internal table that was deleted.
-.You address a field symbol that was previously reset using UNASSIGN or that pointed to a local field that no longer exist.
-. You address a global function interface, although the respective function module is not active - that is, is not in the list of active calls. the list of active calls can be taken from this short dump.
I think that it's for the unicode corversion because I've the last support package 12 installed and the rest of the process chain are running perfect.
My hotmail mail is [email protected] if you need the screen shot.
Regards and thanks a lot
Jose -
ASSERTION_FAILED short dump when Transporting Transformation from Dev to QA
Hi Experts,
I' am getting a short Dump when transporting the transformations, DSO & DTPs from Dev server to QA.
I got RC=12, Please have a look below....
Transport log...
BCQ System BCQ
Selection for Import 08.07.2010 15:28:59 (0) Successfully Completed
Import 08.07.2010 15:35:14 (0) Successfully Completed
Check Versions 08.07.2010 15:35:14 (0) Successfully Completed
Method Execution 08.07.2010 15:36:20 (12) Canceled
Import 08.07.2010 15:45:39 (0) Successfully Completed
Check Versions 08.07.2010 15:45:39 (0) Successfully Completed
Method Execution 08.07.2010 15:46:45 (12) Canceled
and the Log detalis.....
Date Time Message
08.07.2010 15:35:15 Job started
08.07.2010 15:35:15 Step 001 started (program RDDEXECL, variant , user ID DDIC)
08.07.2010 15:35:15 All DB buffers of application server sxcat136 were synchronized
08.07.2010 15:35:21 STDO: Log could not be written on output device T
08.07.2010 15:35:30 Replication completed successfully
08.07.2010 15:35:31 Struttura di comunicazione /BIC/CS8ZFIZIASA activated
08.07.2010 15:35:40 Regola(e) di trasm. 8ZFIZIASA_AA activated
08.07.2010 15:35:47 ABAP/4 processor: ASSERTION_FAILED
08.07.2010 15:35:47 Job cancelled
Even I've checked the entries on the table RSTRANRULE for those Transpormations but there I got...all the entries with...
RULEID = all numbers
GROUPID = '1' or '2'
GROUPTYPE = 'S' or 'T'
REF_RULE ='0'
we are in to SAP_BW Release 700, Level 0013, SP -SAPKW70013, SAP NetWeaver BI 7.0
Pls help if any one know's the solution for this.
Thanks in adv.
BR,
Ajay Kumar
Edited by: sap.ajaykumar on Jul 9, 2010 12:48 PMFollow the steps mentioned in OSS note 998730.
FYI.. Solution:
Call transaction SE16 (Table Browser) and the 'RSTRANRULE' table with the following selection parameters:
GROUPID = 'space'
GROUPTYPE = 'space'
REF_RULE 'space'
If there are inconsistent entries in the RSTRANRULE table such as this:
TRANID *
OBJVERS *
RULEID *
SEQNR *
GROUPID 00
GROUPTYPE space
RULETYPE space
REF RULE *
Delete these entries from the table.
Activate the affected transformations.
Also check the OSS note: 1006658.
Follow the steps mentioned in OSS note 998730.
FYI.. Solution:
Call transaction SE16 (Table Browser) and the 'RSTRANRULE' table with the following selection parameters:
GROUPID = 'space'
GROUPTYPE = 'space'
REF_RULE 'space'
If there are inconsistent entries in the RSTRANRULE table such as this:
TRANID *
OBJVERS *
RULEID *
SEQNR *
GROUPID 00
GROUPTYPE space
RULETYPE space
REF RULE *
Delete these entries from the table.
Activate the affected transformations.
Also check the OSS note: 1006658.
Follow the steps mentioned in OSS note 998730.
FYI.. Solution:
Call transaction SE16 (Table Browser) and the 'RSTRANRULE' table with the following selection parameters:
GROUPID = 'space'
GROUPTYPE = 'space'
REF_RULE 'space'
If there are inconsistent entries in the RSTRANRULE table such as this:
TRANID *
OBJVERS *
RULEID *
SEQNR *
GROUPID 00
GROUPTYPE space
RULETYPE space
REF RULE *
Delete these entries from the table.
Activate the affected transformations.
Also check the OSS note: 1006658.
Also check the oSS note : Note 975675 - Transformation cannot be activated -
Short dump when we write more than 4 routines or formulas 4 one source fld
Hi Experts ,
We have one source field in a DSO which supplies data to 9 other characteristics present in the cube via formulas. But the system throws a short dump when we write more than 4 routines or formulas.
Please let us know if there is any restriction in BI 7 as to let only 4 formulas to be written for one source field.
The below is the description of the short dump
RUNTIME ERROR : SAP SQL_ARRAY_INSERT_DUPREC
EXCEPTION : CX_SY_OPEN_SQL_DB
Help done would be assigned points ...
Thanks,
Santosh ...Hi,
thanks for your input
Rd, rt,re and rs are ranges.
Select ranges
RANGES: rd FOR ZMOBILEDATA-COMPID,
rs FOR ZMOBILEDATA-SUBSCRIBERS,
rt FOR ZMOBILEDATA-TURNOVER,
re FOR ZMOBILEDATA-ENTRYDATE.
thanks' -
Short Dump When Installing Key Figure Catalog from BI Content
Hi Friends,
I get a Short dump when trying to Install a Key Figure Catalog (in Purchasing) from the BI content. This is what the Error Says ,
" You Attempted to Use a "NULL" object reference (Points to nothing) access a component (variable : " "). An Object reference must point to an object (an instance of class ) before it can be used to access components.
Any input will be greatly appreciated,Hi Michal,
this bug hits only patch level 201 of the DBSL. Please update the DBSl.
Regarding the ABAP code I do not believe that the hint helps in this case but it should not cause any problems either. If this hint is applied more PREPARE calls are neccessary since before every execution a new statement text is assembled.
The advantage of SUBSTITUTE_VALUES hints is that the database optimizer get more information through the statement text. The downside is that a new statement is generated every time. E.g. you won't find the statement as a top scorer in a SQL cache analysis if the access plan is still bad.
Regards
Frank -
Short dump when assigning revision to notification (iw22)
Hello!
We have a short dump when we try to assign a revision to a notification in iw22.
The dump occurs when we save after assigning a revision. We have the lollowing message:
Message CO888 : Error when reading order header with index
Include LCOBHIC2, line 39
The OSS note 1101437 doesn't solve our problem.
Can you help me?
Thanks by advance,
Laurent.I tried your tests.
I haven't a dump neither for the first test nor for the second one.
The dump occurs only when:
- I create a notification
- i create an order and assign it to this notification.
- i save the notification and the order
- i assign a revision to the notifiaction and save
There isn't dump if i assign revision number before the order creation. In fact, the dump only occurs if a assign a revision number after the assignment of the order to the notifiation.
I'm checking user exit.
Thanks,
Laurent. -
Short dump when executing the query
Hello Friends,
I have a query from MM area which I have insalled from Business Content , and when I try to go to the edit mode or try to excute the query I get a short dump which says "Missing elements ..", I get the same dump when executing from query designer or RSRT . At this time I'm not able to do a "check" on the query also n query designer since it doesnot allow me to go to the edit mode also . Any inputs greatly appreciated .
thanks ,Hi,
While activating it from the Business Content, have you activated all the underlying objects also. Pls check that. It might help. -
Sub totaling in the ALV report
Hi,
My requirement is to display the data in a ALV format. The ALV need to display the sub total. For example if the ALV display the comapny code, the number of the line of the company code need to displayed.
1000
1000
1000
Sub total 3
2000
2000
2000
2000
sub total 4
I made the changes to display the ALV. Please help mein obtaining the sub total..
Regards
SureshHI,
Below example may clear ur requirement.
REPORT YMS_ALVSUBTOTAL.
*REPORT z_alv_sub_totals .
TYPE-POOLS: slis.
DATA: BEGIN OF it_output OCCURS 0,
var1(8) TYPE n,
var2(10),
var3 TYPE I,
END OF it_output.
DATA: it_fieldcat TYPE slis_t_fieldcat_alv,
t_fieldcat TYPE slis_fieldcat_alv,
it_sort TYPE slis_t_sortinfo_alv,
t_sort TYPE slis_sortinfo_alv,
v_repid LIKE sy-repid.
INITIALIZATION.
v_repid = sy-repid.
START-OF-SELECTION.
PERFORM get_data.
PERFORM sort_fields.
PERFORM fill_fieldcat.
PERFORM list_display.
*& Form GET_DATA
text
--> p1 text
<-- p2 text
FORM get_data.
it_output-var1 = 1000.
it_output-var2 = 'anupama'.
it_output-var3 = '10000'.
APPEND it_output.
CLEAR it_output.
it_output-var1 = 1000.
it_output-var2 = 'siddhu'.
it_output-var3 = '20000'.
APPEND it_output.
CLEAR it_output.
it_output-var1 = 1000.
it_output-var2 = 'chinni'.
it_output-var3 = '100000'.
APPEND it_output.
CLEAR it_output.
it_output-var1 = 2000.
it_output-var2 = 'chicchu'.
it_output-var3 = '10000'.
APPEND it_output.
CLEAR it_output.
it_output-var1 = 2000.
it_output-var2 = 'candy'.
it_output-var3 = '10000'.
APPEND it_output.
CLEAR it_output.
it_output-var1 = 1000.
it_output-var2 = 'anupama'.
it_output-var3 = '10000'.
APPEND it_output.
CLEAR it_output.
it_output-var1 = 4000.
it_output-var2 = 'anupama'.
it_output-var3 = '10000'.
APPEND it_output.
CLEAR it_output.
ENDFORM. " GET_DATA
*& Form fill_fieldcat
text
--> p1 text
<-- p2 text
FORM fill_fieldcat.
PERFORM fill_fields USING: 'IT_OUTPUT' 'VAR1' 'Variable 1' ' ',
'IT_OUTPUT' 'VAR2' 'Variable 2' ' ',
'IT_OUTPUT' 'VAR3' 'Variable 3' 'X'.
ENDFORM. " fill_fieldcat
*& Form fill_fields
text
-->P_0146 text
-->P_0147 text
-->P_0148 text
-->P_0149 text
FORM fill_fields USING value(tabname) TYPE slis_tabname
value(fieldname) TYPE slis_fieldname
value(seltext_m) LIKE dd03p-scrtext_m
value(do_sum) TYPE c.
t_fieldcat-tabname = tabname.
t_fieldcat-fieldname = fieldname.
t_fieldcat-seltext_m = seltext_m.
IF do_sum = 'X'.
t_fieldcat-datatype = 'CURR'.
ENDIF.
t_fieldcat-do_sum = do_sum.
APPEND t_fieldcat TO it_fieldcat.
CLEAR t_fieldcat.
ENDFORM. " fill_fields
*& Form list_display
text
--> p1 text
<-- p2 text
FORM list_display.
CALL FUNCTION 'REUSE_ALV_LIST_DISPLAY'
EXPORTING
i_callback_program = v_repid
it_fieldcat = it_fieldcat
it_sort = it_sort[]
TABLES
t_outtab = it_output
EXCEPTIONS
program_error = 1
OTHERS = 2
IF sy-subrc <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
ENDFORM. " list_display
*& Form sort_fields
text
--> p1 text
<-- p2 text
FORM sort_fields.
t_sort-fieldname = 'VAR1'.
t_sort-tabname = 'IT_OUTPUT'.
t_sort-spos = 1.
t_sort-up = 'X'.
t_sort-subtot = 'X'.
APPEND t_sort TO it_sort.
CLEAR t_sort.
t_sort-fieldname = 'VAR3'.
t_sort-tabname = 'IT_OUTPUT'.
t_sort-spos = 2.
t_sort-up = 'X'.
APPEND t_sort TO it_sort.
CLEAR t_sort.
ENDFORM. " sort_fields
Thanks,
Shankar -
Regarding totals and sub totals text in alv
Hi all,
i am displaying Totals and subtotals ......but i want to display the text before the the Totals and Subtotals.
Please help me in regarding this..
Thanks in advance,
S.Gangi reddy.hi,
check this report.
*& Report ZGM_ALV_SUBTOTAL_TEXT *
*& Author :
*& Date :
*& Description :
*& Modification History
REPORT ZGM_ALV_SUBTOTAL_TEXT .
*& Table declaration
TABLES: ekko.
*& Type pool declaration
TYPE-POOLS: slis. " Type pool for ALV
*& Selection screen
SELECT-OPTIONS: s_ebeln FOR ekko-ebeln.
*& Type declaration
Type declaration for internal table to store EKPO data
TYPES: BEGIN OF x_data,
ebeln TYPE char30, " Document no.
ebelp TYPE ebelp, " Item no
matnr TYPE matnr, " Material no
matnr1 TYPE matnr, " Material no
werks TYPE werks_d, " Plant
werks1 TYPE werks_d, " Plant
ntgew TYPE entge, " Net weight
gewe TYPE egewe, " Unit of weight
END OF x_data.
*& Internal table declaration
DATA:
i_ekpo TYPE STANDARD TABLE OF x_data INITIAL SIZE 0,
Internal table for storing field catalog information
i_fieldcat TYPE slis_t_fieldcat_alv,
Internal table for Top of Page info. in ALV Display
i_alv_top_of_page TYPE slis_t_listheader,
Internal table for ALV Display events
i_events TYPE slis_t_event,
Internal table for storing ALV sort information
i_sort TYPE slis_t_sortinfo_alv,
i_event TYPE slis_t_event.
*& Work area declaration
DATA:
wa_ekko TYPE x_data,
wa_layout TYPE slis_layout_alv,
wa_events TYPE slis_alv_event,
wa_sort TYPE slis_sortinfo_alv.
*& Constant declaration
CONSTANTS:
c_header TYPE char1
VALUE 'H', "Header in ALV
c_item TYPE char1
VALUE 'S'.
*& Start-of-selection event
START-OF-SELECTION.
Select data from ekpo
SELECT ebeln " Doc no
ebelp " Item
matnr " Material
matnr " Material
werks " Plant
werks " Plant
ntgew " Quantity
gewei " Unit
FROM ekpo
INTO TABLE i_ekpo
WHERE ebeln IN s_ebeln
AND ntgew NE '0.00'. IF sy-subrc = 0.
SORT i_ekpo BY ebeln ebelp matnr .
ENDIF.
To build the Page header
PERFORM sub_build_header. "* To prepare field catalog
PERFORM sub_field_catalog. "* Perform to populate the layout structure
PERFORM sub_populate_layout."* Perform to populate the sort table.
PERFORM sub_populate_sort."* Perform to populate ALV event
PERFORM sub_get_event.
END-OF-SELECTION.
* Perform to display ALV report
PERFORM sub_alv_report_display.
*& Form sub_build_header
To build the header
No Parameter
FORM sub_build_header .
Local data declaration
DATA: l_system TYPE char10 , "System id
l_r_line TYPE slis_listheader, "Hold list header
l_date TYPE char10, "Date
l_time TYPE char10, "Time
l_success_records TYPE i, "No of success records
l_title(300) TYPE c. " Title
Title Display
l_r_line-typ = c_header. " header
l_title = 'Test report'(001).
l_r_line-info = l_title.
APPEND l_r_line TO i_alv_top_of_page.
CLEAR l_r_line.
* Run date Display
CLEAR l_date.
l_r_line-typ = c_item. " Item
WRITE: sy-datum TO l_date MM/DD/YYYY.
l_r_line-key = 'Run Date :'(002).
l_r_line-info = l_date.
APPEND l_r_line TO i_alv_top_of_page.
CLEAR: l_r_line,
l_date.ENDFORM. " sub_build_header
*& Form sub_field_catalog
Build Field Catalog
No Parameter
FORM sub_field_catalog .
Build Field Catalog
PERFORM sub_fill_alv_field_catalog USING: '01' '01' 'EBELN'
'I_EKPO' 'L'
'Doc No'(003) ' ' ' ' ' ' ' ', '01' '02' 'EBELP' 'I_EKPO' 'L'
'Item No'(004) 'X' 'X' ' ' ' ', '01' '03' 'MATNR' 'I_EKPO' 'L'
'Material No'(005) 'X' 'X' ' ' ' ', '01' '03' 'MATNR1' 'I_EKPO'
'L'
'Material No'(005) ' ' ' ' ' ' ' ',
'01' '04' 'WERKS' 'I_EKPO' 'L'
'Plant'(006) 'X' 'X' ' ' ' ', '01' '04' 'WERKS1' 'I_EKPO' 'L'
'Plant'(006) ' ' ' ' ' ' ' ', '01' '05' 'NTGEW' 'I_EKPO' 'R'
'Net Weight'(007) ' ' ' ' 'GEWE' 'I_EKPO'.ENDFORM.
" sub_field_catalog*&----
*& Form sub_fill_alv_field_catalog
*& For building Field Catalog
*& p_rowpos Row position
*& p_colpos Col position
*& p_fldnam Fldname
*& p_tabnam Tabname
*& p_justif Justification
*& p_seltext Seltext
*& p_out no out
*& p_tech Technical field
*& p_qfield Quantity field
*& p_qtab Quantity table
FORM sub_fill_alv_field_catalog USING p_rowpos TYPE sycurow
p_colpos TYPE sycucol
p_fldnam TYPE fieldname
p_tabnam TYPE tabname
p_justif TYPE char1
p_seltext TYPE dd03p-scrtext_l
p_out TYPE char1
p_tech TYPE char1
p_qfield TYPE slis_fieldname
p_qtab TYPE slis_tabname.
Local declaration for field
catalog
DATA: wa_lfl_fcat TYPE slis_fieldcat_alv.
wa_lfl_fcat-row_pos = p_rowpos. "Row
wa_lfl_fcat-col_pos = p_colpos. "Column
wa_lfl_fcat-fieldname = p_fldnam. "Field Name
wa_lfl_fcat-tabname = p_tabnam. "Internal Table Name
wa_lfl_fcat-just = p_justif. "Screen Justified
wa_lfl_fcat-seltext_l = p_seltext. "Field Text
wa_lfl_fcat-no_out = p_out. "No output
wa_lfl_fcat-tech = p_tech. "Technical field
wa_lfl_fcat-qfieldname = p_qfield. "Quantity unit
wa_lfl_fcat-qtabname = p_qtab .
"Quantity table
IF p_fldnam = 'NTGEW'.
wa_lfl_fcat-do_sum = 'X'.
ENDIF.
APPEND wa_lfl_fcat TO i_fieldcat.
CLEAR wa_lfl_fcat.
ENDFORM.
" sub_fill_alv_field_catalog*&----
*& Form sub_populate_layout
Populate ALV layout
No Parameter
FORM sub_populate_layout . CLEAR wa_layout.
wa_layout-colwidth_optimize = 'X'.
" Optimization of Col width
ENDFORM. " sub_populate_layout*&----
*& Form sub_populate_sort
Populate ALV sort table
No Parameter
FORM sub_populate_sort .
Sort on material
wa_sort-spos = '01' .
wa_sort-fieldname = 'MATNR'.
wa_sort-tabname = 'I_EKPO'.
wa_sort-up = 'X'.
wa_sort-subtot = 'X'.
APPEND wa_sort TO i_sort .
CLEAR wa_sort.
Sort on plant
wa_sort-spos = '02'.
wa_sort-fieldname = 'WERKS'.
wa_sort-tabname = 'I_EKPO'.
wa_sort-up = 'X'.
wa_sort-subtot = 'X'.
APPEND wa_sort TO i_sort .
CLEAR wa_sort.
ENDFORM.
" sub_populate_sort*&----
*& Form sub_get_event
Get ALV grid event and pass the form name to subtotal_text
event
No Parameter
FORM sub_get_event .
CONSTANTS : c_formname_subtotal_text TYPE slis_formname VALUE
'SUBTOTAL_TEXT'. DATA: l_s_event TYPE slis_alv_event.
CALL FUNCTION 'REUSE_ALV_EVENTS_GET'
EXPORTING
i_list_type = 4
IMPORTING
et_events = i_event
EXCEPTIONS
list_type_wrong = 0
OTHERS = 0.
Subtotal
READ TABLE i_event INTO l_s_event
WITH KEY name = slis_ev_subtotal_text.
IF sy-subrc = 0.
MOVE c_formname_subtotal_text TO l_s_event-form.
MODIFY i_event FROM l_s_event INDEX sy-tabix.
ENDIF.ENDFORM.
" sub_get_event*&----
*& Form sub_alv_report_display
For ALV Report Display
No Parameter
FORM sub_alv_report_display .
DATA: l_repid TYPE syrepid .
l_repid = sy-repid .
This function module for displaying the ALV
report
CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
EXPORTING
i_callback_program = l_repid
i_callback_top_of_page = 'SUB_ALV_TOP_OF_PAGE'
is_layout = wa_layout
it_fieldcat = i_fieldcat
it_sort = i_sort
it_events = i_event
i_default = 'X'
i_save = 'A'
TABLES
t_outtab = i_ekpo
EXCEPTIONS
program_error = 1
OTHERS = 2.
IF sy-subrc <> 0.
MESSAGE i000 WITH 'Error in ALV report display'(055).
ENDIF.
ENDFORM.
" sub_alv_report_display*&----
FORM sub_alv_top_of_page
Call ALV top of page
No parameter
FORM sub_alv_top_of_page. "#EC CALLED*
*To write header for the ALV
CALL FUNCTION 'REUSE_ALV_COMMENTARY_WRITE'
EXPORTING
it_list_commentary = i_alv_top_of_page.
ENDFORM.
"alv_top_of_page*&----
*& Form subtotal_text
Build subtotal text
P_total Total
p_subtot_text Subtotal text info
FORM subtotal_text CHANGING
p_total TYPE any
p_subtot_text TYPE slis_subtot_text.
Material level sub total
IF p_subtot_text-criteria = 'MATNR'.
p_subtot_text-display_text_for_subtotal
= 'Material level total'(009).
ENDIF.
Plant level sub total
IF p_subtot_text-criteria = 'WERKS'.
p_subtot_text-display_text_for_subtotal = 'Plant level total'(010).
ENDIF.
ENDFORM. "subtotal_textSelection screen:
\[removed by moderator\]
Edited by: Jan Stallkamp on Sep 3, 2008 6:17 PM -
This is regarding totals and sub totals in sap-scripts
Hi to all...............
1...How to print totals and subtotals in sap-scripts? where we have to code the logic.what sort of logic is needed to print the same?
regards,
swaminath.Hi
HI,
To calculate totals and sub totals in sap scripts you have to use subroutines.
Say if you have to add the unit price (KOMVD-KBERT) then in the main window whereever tat value is picked write this routine
/: DEFINE &TOT_PRICE&
/: PERFORM F_GET_PRICE IN PROGRAM <subroutine prog name> /:USING &KOMVD-KBERT& /:CHANGING &TOT_PRICE& /:ENDPERFORM
Then write the variable where ever you want it to be printed (mostly it will be in footer window)
Then create subroutine pool program and you have to write the code.
FORM F_GET_PRICE tables int_cond structure itcsy
outt_cond structure itcsy. data : value type kbert.
statics value1 type kbert.
Read int_cond table index 1.
value = int_cond-value.
value1 = value1 + value.
Read outt_cond table index 1.
outt_cond-value = value1.
Modify outt_cond index 1.
ENDFORM.
To know more, have a look at this thread ..
Re: SAP Script: Display Total calculated on page 2 in page 1
<b>Reward if usefull</b> -
How to do the ALV report output in groups and caluculate the tOTALS(URGENT
Hi
In my ALV report output .I have to group the output based on the DAYS field
0-10 days in one group
10-30 days in one group
above 30 days one group
There is also a field by name "AMOUNT" in my output.
I have to calculate SUBTOTALs at the end of every group and at the end of the report i should caluculate GRAND TOTAL.
Please remember that i should not use any any BLOCKED ALVs and for Totals i should not use the SYMBOLS provided in the application toolbar of the report
Thanks in AdvancePlease don't repost your questions...
Check out my answer in your other post.
How to make the ALV report in groups and caluculate the TOTALS
Regards,
Naimesh Patel -
Problem when dowloading the ALV report output to Excel Sheet.
Hi ,
I am dowloading the ALV report output to Excel Sheet.
There is field Condition Unit(KOMP-KMEIN) in the output of the ALV, this has values PC and CSE , but when I download to Excel Sheet, CSE is appearing as CSE ,but PC is appearing as ******.
Can you please help me in knowing the reson for this.
Regards,
Madhu.hi
refer to following link
http://www.****************/Tutorials/ALV/ColorSALV/Demo.htm
http://www.sap-img.com/abap/download-to-excel-with-format-border-color-cell-etc.htm
Cheers
Snehi
Edited by: snehi chouhan on Jul 11, 2008 12:42 PM
Maybe you are looking for
-
IMP Fails when using multi-file export
IMP-00051: Direct path exported dump file contains illegal column length IMP-00008: unrecognized statement in the export file: I exported to two 2.0 gig files on linux 816 then simply copied them to another 816 server and attemped to import, it seems
-
Final cut 7 operating slow on OSX 10.8.5
Hello there Wondering if anyone can assist me in troubleshooting a super slow FCP 7.0.3 on an iMac ( 3.4 GHz Intel Core i7, 4 GB 1333 MHz DDR3). The system seems to freeze up constantly when scrubbing through/playing/editing clips. Is there a bette
-
Firefox will not open st george bank logon window
Firefox will not open the St George logon window. It has for morre than 5 years but in the last 48 hours it has stopped. IE and Crome still do. We have cached web content, opened Firefox in safe mode, uninstalled and reinstalled Firefox 6 times and t
-
Certification Questions about SAP financials
Hi, I'm planning to join in this SAP Certified Application Associate - Financial Accounting module. Please suggest me the following and additional details: 1. What are the prescribed books for this module? 2. What are the procedures to take certifica
-
Hi All, i've a string holding the value as given below. AA,17,2/19/2003,"9,999.00",USD,00,10,318,"193,275.31" by performing some string operations i want the result string in the format as given below: AA,17,2/19/2003,"9999.00",USD,00,10,318,"193,275