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: 

Performance Tunning

Former Member
0 Kudos

Hi,

can someone tell me is rsdb/max_blocking_factor.

What is this used for and how do we calculate this factor??

Thanks,

Supriya Manik.

3 REPLIES 3

Former Member
0 Kudos

Hi

In connection with SELECT ... FOR ALL ENTRIES the following problems occur:

1)You cannot have an empty internal driver table. If the driver table is empty, selection is not limited. In particular, WHERE clause conditions are not evaluated if they do not refer to the internal driver table.

2)Duplicate table entries should be deleted from the internal table before executing the SELECT... FOR ALL ENTRIES. If they are not deleted, identical data is read unnecessarily from the database.

<b>3)The parameter rsdb/max_blocking_factor must be implemented according to SAP's database-specific recommendations</b>.

<b>Reward if usefull</b>

Former Member
0 Kudos

Hi Sirisha,

if you look into the documentation you'll find the following description (RZ11 -> Documentation):

Parameter : rsdb/max_blocking_factor

Short description: Split factor for FOR ALL ENTRIES queries

Parameter description :

This parameter is for internal use only and must never be

changed without the prior consent of SAP.

An internal table [itab] with input data is always transferred in

case of an ABAP SELECT request with the addition FOR ALL ENTRIES.

The profile parameter defines the upper limit for the number of

[itab] entries to be processed in a single statement. That is, if

internal table specified in the FOR ALL ENTRIES clause has more than

rsdb/max_blocking_factor rows, the Open SQL statement is divided

multiple steps with regard to the database. Their individual results

are collected in the database interface and then returned to the

ABAP program as the entire result. This means that for an internal

table with N rows,

N / "rsdb/max_blocking_factor" + 1

individual SELECT statements are performed on the database.

However, this parameter has no effect on the mapping for IN (...) -

see the documentation for rsdb/prefer_in_itab_opt.

The technical maximum blocking factor is also calculated for each

statement, to ensure that no database system limits are exceeded.

If the blocking factor limit is smaller than max_blocking_factor,

this limit is implicitly used.

Application area: Database

Unit :

Default value:

The default value is database-dependent. For technical reasons, it

is unfortunately necessary to enter a common, artificial value (-1).

The original default values for each database system are listed

below. Caution: Since these values can be changed by kernel patches,

it is important that you obtain the current default values from SAP

Note 48230.

DB2/390: 10

DB2 UDB: 10

Informix: 20

iSeries: 20

MaxDB: 10

MS SQL Server: 50

Oracle: 15

Who is permitted to make changes:

Limitations for operating systems:

Limitations for database systems:

Other Parameters Affected or Dependent:

rsdb/prefer_in_itab_opt

Valid Input, Formats, Areas:

Hope this helps

Regards

Ralph

former_member194613
Active Contributor
0 Kudos

The max_blocking_factor is the maximal number of records of one fetch in a FOR ALL ENTRIES execution, see SQL Trace. It must be limited otherwise some databases would overestimate the result set of the select and would not use an index for the select anymore. It is database specific.

It is there, but you do not use it!

Siegfried