Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

Buffering

Former Member
0 Kudos

Hi,

What is Buffering? Types ?

Uses of Buffering

I look forward to your reply

Thanks

SEK

7 REPLIES 7

suresh_datti
Active Contributor
0 Kudos

Did you check this <a href="http://help.sap.com/saphelp_47x200/helpdata/en/c4/3a6de2505211d189550000e829fbbd/frameset.htm">SAP Help</a>?

Regards,

Suresh Datti

0 Kudos

former_member181962
Active Contributor
0 Kudos

see this:

Regards,

Ravi

Former Member
0 Kudos

Hi,

Buffering is the property that can be set for a database table. It means that the records of this table are in the buffer for faster access. You can specify whether you want to buffer the entire table or a single record.

The Individual Buffering Types :

Permanent (P)


This is the default buffer setting, in which the cross-transaction application buffer is used. For more information about this buffer, see the keyword documentation for EXPORT/IMPORT TO/FROM SHARED BUFFER. The cross-transaction application buffer can contain up to 128 context entries. These entries are structured using a process similar to LRU (Least Recently Used).

To display the contents of the context buffer on the current application server, choose Goto ® Display buffer in the Context Builder. The buffer is reset every hour on the hour. You can also reset it manually in the Context Builder by choosing Edit ® Reset buffer. This resets the buffer on all application servers.

Temporary (T)


If you choose this buffer type, the derived data is only buffered within a transaction. Within a transaction the buffer can contain up to 1024 entries. These entries are exported in bundles into the cross-transaction application buffer. The results of the various instances of a context are stored in the same buffer within the program.

No buffer (N)

If you choose No buffer, the derived data is not buffered. If you use this buffering type for all modules in a context, using the context will not improve system performance, but is merely a way of re-using program logic.

Permanent buffering can lead to problems when you are testing your Customizing settings. The Context Builder therefore allows you to de-activate the context buffer (buffering type P) during the current terminal session. To do this, choose Settings ® Buffering. The system displays a dialog box. Select Inactive, and choose Continue. You can activate or de-activate the context buffer for a particular user by setting the user parameter BUF to Y or SPACE (default) or N using the Maintain users transaction (SU01).

Regards,

Aswin

Former Member
0 Kudos

chk this , very good one

Former Member
0 Kudos

To decide if you will use buffering, you should consider the following issues:

· Are the inconsistencies that may arise between different cluster nodes within a buffer synchronization period acceptable?

· Is the table mostly used for reading or for writing?

· How large is the buffered part of the table?

You can use the following general hints when deciding if you want your table buffered:

...

1. You should buffer tables that are mostly read and rarely changed, which is why certain inconsistencies are acceptable. Buffering is recommended for smaller tables. Large tables are usually indexed.

2. Choose the buffer granularity for the table carefully. This depends on the following issues:

¡ The expected size of the table. Full buffering is not recommended for large tables.

¡ Read accesses. To use the buffer you have to provide the defined key range – that is, the generic key and the primary key.

¡ Non-existent data. With single records buffering each not found record is stored as an entry. For generic area buffering an entry is stored for each not found generic area. The potential overload is avoided when you use full buffering. We recommend that you use full buffering for empty tables with frequent write accesses.

3. It is important to choose an appropriate generic key. A short generic key may lead to a large number of buffered records. A large generic key usually means a small number of buffered records. The queries then often will bypass the buffer and buffering will not be efficient.

rahulkavuri
Active Contributor
0 Kudos

A good example where buffering is used is "HIDE"

fORM DISPLAY_DATA.

DATA: LINNO TYPE I.
SORT IT_EKKO BY BUKRS LIFNR EBELN.

LOOP AT IT_EKKO.
READ TABLE IT_LFA1 WITH KEY LIFNR = IT_EKKO-LIFNR.

SELECT SINGLE BUTXT FROM T001 INTO (V_BUTXT)
WHERE BUKRS = IT_EKKO-BUKRS.

WRITE:/1 SY-VLINE,
(10) IT_EKKO-EBELN HOTSPOT ON,
SY-VLINE,
(10) IT_EKKO-LIFNR HOTSPOT ON,
SY-VLINE,
(15) IT_LFA1-NAME1 HOTSPOT ON,
SY-VLINE,
(10) IT_EKKO-BUKRS HOTSPOT ON,
SY-VLINE,
(15) V_BUTXT,
75 SY-VLINE.

<b>HIDE: IT_EKKO-EBELN,
IT_EKKO-LIFNR.</b>

WRITE:/1(75) SY-ULINE.

AT END OF LIFNR.
LINNO = SY-LINCT - SY-LINNO - 1.
SKIP LINNO.
ENDAT.

ENDLOOP.

ENDFORM. " DISPLAY_DATA