On a previous project using Mysql database I had to use ANALYZE tablename when a lot of data was added to the table so that the database created sensible query plans for SQL.
Now I’m using H2 with Hibernate, do I need to worry about this anymore or does Hibernate look after this for me?
Except in very special cases, you no longer need to manually run the statement
ANALYZE, because recent versions of H2 automatically update the statistics from time to time (you can change this setting by the way). It was required in older versions of H2 (I forgot the exact time the auto-analyze was implemented, I think about two years ago).