I can observe that user tables without records get StatisticUpdateDate = null, but I have user tables with records that StatisticUpdateDate = null.
The last statistics update is null, and now?
Why is StatisticsUpdatedate is null? How to fix it ?
The script is :
SELECT *, OBJECT_NAME(object_id) AS [ObjectName]
,[name] AS [StatisticName]
,STATS_DATE([object_id], [stats_id]) AS [StatisticUpdateDate]
FROM sys.stats;
Best regards,
Miguel
2 additional answers
Sort by: Newest
-
Miguel Gavinhos 216 Reputation points
2021-10-22T19:42:38.227+00:00 It looks by design, and I can see that I have a bunch of user tables with a persistent statistics update date = 'null' that by no method can I get it changed from null to a date. I'm not saying that it is always or never I have no data to support this statement. The methods are https://ola.hallengren.com/sql-server-index-and-statistics-maintenance.html and sp_MSforeachdb 'use [?]; exec sp_updatestats'. I'm I missing something?
-
Tom Phillips 17,716 Reputation points
2021-10-22T14:25:31.443+00:00 That is perfectly normal. It just means the stats have not been updated since they were created.
Are you having an issue of some kind?