cancel
Showing results for 
Search instead for 
Did you mean: 

How does auto_update_statistics work?

Former Member
0 Kudos

Hi all,

just a simple question: What do I have to do that auto_update_statistics do work?

I activated the auto_update_statistics for my DB a long time ago, expecting all the rest would run by itself. That means, no check if update statistics is nessesary or refresh statistics.

Now I just run a check update statistics and there are tons of tables need to be updated. How is this possible?

Best regards

Christian G

Accepted Solutions (1)

Accepted Solutions (1)

lbreddemann
Active Contributor
0 Kudos

>

> Hi all,

>

> just a simple question: What do I have to do that auto_update_statistics do work?

>

> I activated the auto_update_statistics for my DB a long time ago, expecting all the rest would run by itself. That means, no check if update statistics is nessesary or refresh statistics.

>

> Now I just run a check update statistics and there are tons of tables need to be updated. How is this possible?

Hi Christian,

how did you check whether the statistics needed an update?

The automatic stats update is based on the system table [SYSUPDSTATWANTED

|http://maxdb.sap.com/doc/7_7/45/2d525dd79f3446e10000000a155369/content.htm].

Whenever the optimizer realizes that the statistics aren't fitting anymore to what it actually finds in the tables during joins (and joins only!), it enters the table name to this system table.

The automatic statistics update is then triggered to gather new stats on the tables in the system table.

Therefore this is a reactive process and therefore not what we want to have in a SAP system.

That is basically the reason for why this feature is not supported to be used with SAP systems.

regards,

Lars

Former Member
0 Kudos

Hi Lars,

thats nice to know, I checked the statistics with DB13 (UPD_CHECK) but this is SAP technology using SAP tables (DBSTATC) and so on.

The rest of my questions were solved by note 927882 - FAQ: MaxDB Update Statistics.

Thank you.

Best regards

Christian G

Answers (0)