‎2008 Aug 27 12:19 PM
Hi Gurus,
How to clear a buffer memory in a report program?
Regards,
Amit Kumar Singh
‎2008 Aug 27 12:23 PM
‎2008 Aug 27 12:25 PM
‎2008 Aug 27 12:27 PM
hii
you can use FREE MEMORY statement after importing data or use it in end-of-selection event in program for clearing buffer memory.
regards
twinkal
‎2008 Aug 27 12:29 PM
You need to use FREE statement...
In other scenario....
EXPORT it_steps TO DATABASE indx(ar) CLIENT sy-mandt ID 'ZCRPROP'.
IMPORT it_steps FROM DATABASE indx(ar) CLIENT sy-mandt ID 'ZCRPROP'.
DELETE FROM DATABASE indx(ar) CLIENT sy-mandt ID 'ZCRPROP'.
‎2008 Aug 27 12:57 PM
Hi,
type FREE in your abap progam and press F1. you will come to know
Cheers,
chinna
‎2008 Aug 27 1:07 PM
Hi Amit,
Are you working with ALV report ?
If so, plz run the following Abap, which will reset buffer :
BALVBUFDEL
Hope this helps,
Erwan
‎2008 Aug 27 1:31 PM
Hi Erwan,
Yes i am working with a report.
I tried using with statement.
submit BALVBUFDEL and return.
But it's not working.
Please suggest.
Regards,
Amit Kumar Singh
‎2008 Aug 27 1:42 PM
Humm...
In fact it enable to reset buffer while you are working on your report, in order that new feature can appear...
I run it between two changes.
What is your problem ?
Once your report is done, between two execution you should'nt encounter problem of buffer ( Don't forget to exit SE/SA38 and to return.
Erwan
‎2008 Aug 27 2:18 PM
Hi Erwan,
I am trying to use a Refresh button on an ALV report output.
Whenever I click on the refresh button it again calls all the select queries.
In that select query I am using one function module 'STATUS_READ'.
This fm is giving the same result that it was giving when the report is run for the first time even though the value is changed now.
If I execute the program again then program gives the correct output.
Regards,
Amit Kumar Singh
‎2008 Aug 27 2:21 PM
Hi
Check these code snippets
https://www.sdn.sap.com/irj/sdn/wiki?path=/display/snippets/autorefreshalv+Program
https://www.sdn.sap.com/irj/sdn/wiki?path=/display/snippets/refresh+alvtree
Regards
Pavan
‎2008 Aug 27 2:23 PM
Ah OK.
Are you using the USER COMMAND sub-routine in your ALV function ?
This is what you have to use, to perform that.
‎2008 Aug 27 2:42 PM
Yes i am using USER__COMMAND like this
----
FORM USER_COMMAND *
----
FORM user_command USING u_ucomm TYPE sy-ucomm
us_selfield TYPE slis_selfield. "#EC CALLED
data : l_memory_id(20) type c value 'BSVA_BUFFER'.
free memory ID l_memory_id.
CASE u_ucomm.
WHEN gc_refresh.
PERFORM clear_data.
CONCATENATE '-' p_months INTO p_months.
PERFORM populate_z01. "List of Plants and Materials
PERFORM populate_z02. "List of Periods and dates
PERFORM populate_z03. "Report Contents
PERFORM add_data.
us_selfield-refresh = c_x.
us_selfield-col_stable = c_x.
us_selfield-row_stable = c_x.
ENDCASE.
*
ENDFORM. "user_command
----
FORM PF_STATUS_SET *
----
FORM pf_status_set USING ut_extab TYPE slis_t_extab. "#EC CALLED
DELETE ut_extab WHERE fcode = gc_refresh.
SET PF-STATUS 'STANDARD_FULLSCREEN' OF PROGRAM 'SAPLKKBL'
EXCLUDING ut_extab.
ENDFORM. "pf_status_set
Where gc_refresh is defined as
constants : gc_refresh TYPE syucomm VALUE '&REFRESH'.
‎2008 Aug 28 6:00 AM
Hi all,
Thanks for all your support.
Now my problem has been resolved.
I used FM 'STATUS_BUFFER_REFRESH' . This refres the buffer memory.
Regards,
Amit Kumar Singh
‎2008 Aug 27 1:10 PM
‎2008 Aug 27 1:38 PM
Hello Amit.
I would like to suggest my opinion.
Transaction AL12 - Display Table Buffers.
There is an option in
EDIT go to RESET Buffers.Lot of options available.
Especially, check the Option
EXP/IMP MemoryAnother Alternative,
Transaction CNV_RESET - Reset all table Buffers.
Hope this works out.
Good Luck & Regards.
Harsh Dave