To check if auto update is enabled on statistics, try this command

show variables like '%metadata%';
If you see an output such as:
innodb_stats_auto_recalc = 1, you're all set..

If you see an output such as:

 innodb_stats_on_metadata | ON    |

it means that statistics get updated whenever metadata on the table is requested, which is typically enough. But , you may still need to set that first variable –

innodb_stats_auto_recalc = 1

Here is some more info on this topic – https://mariadb.com/kb/en/library/xtradbinnodb-server-system-variables/#innodb_stats_auto_recalc

For cloud migration projects or cloud consulting on AWS, GCP or Azure, contact Cloud Migration Architect

Anuj holds professional certifications in Google Cloud, AWS as well as certifications in Docker and App Performance Tools such as New Relic. He specializes in Cloud Security, Data Encryption and Container Technologies.

Initial Consultation

Anuj Varma – who has written posts on Anuj Varma, Hands-On Technology Architect, Clean Air Activist.