Application Development and Automation 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: 
Read only

DB05 transaction

Former Member
0 Likes
1,999

Dear All,

Do you have any idea what DB05 transaction does and it helps us in some way to improve the performance of the program?

Please let me know if you have some documentation about this transaction.

Regards,

Tarun

Dear All,

Do you have any idea what DB05 transaction does and it helps us in some way to improve the performance of the program?

Please let me know if you have some documentation about this transaction.

Regards,

Tarun

6 REPLIES 6
Read only

ThomasZloch
Active Contributor
0 Likes
1,334

* ------------------------------------------------------------------
* Report rsdb0005 (Transaction DB05)
*  this report calculates the selectivity of an index

It shows the distribution of distinct values for a given combination of fields of a given table, helps you decide whether a secondary index would be efficient.

Thomas

Read only

0 Likes
1,334

Hello Thomas,

How do i determine if secondary index is helpful or giving good results by looking at DB05 transaction?

Regards,

Tarun

Read only

0 Likes
1,334

Hi Tarun,

Please check the below links,

Best Regards.

Read only

0 Likes
1,334

Good selectivity is when by specifying the key values the returned rows can be reduced significantly, to a small fraction of the overall number of rows in the table.

DB05 shows you the number of distinct values and the distribution. The more distinct values, the better.

Try with table EKKO:

- run for primary key: perfect selectivity (no surprise, it's unique after all)

- run for MANDT and BUKRS, well...

Thomas

Read only

Former Member
0 Likes
1,334

Hi,

but be careful, there is biig difference between DB05 and optimizer evaluation of selectivity!

Assume the index has 2 fields:

The DB05 shows the number of different values for

field1 and for the combination (field1, field2)

The optimizer sees usually only the number of different values for

field1 and field2.

It assumes the (field1, field2) has #field1 * #field2 different values. This is usually

different from the actual number.

That is the difference, and the DB05 shows also a part of the distribution of the values,

wether there are values which are taken by many records, i.e. whether the distribution

is unequal.

=> this function makes the DB05 slow.

The actual use case for the DB05 is the test for buffer settings.

If you need the statistical values, then better check the ST05, call data with the Se16 and

trace it, the ST05 shows the statistics for IBM and Oracle databases. In Microsoft and Max DB

the values are not shown.

=> Check DB02, in new releases it also shows statistics.

Siegfried

.... break to be continued ...

Read only

Former Member
0 Likes
1,334

Hi ,

From DB05 transaction you will come to know about the table records according to the primary key and client . You also able to know about the buffering .

If you want to know about the contents according to specified fields you can specify those fields.

Regards

Pinaki Mukherjee