???????????????

?????????????????

?????????????????????????????????????????к??????????????????????????????????????????????????????????SQLServer????????????????????????where??on????????????????????????????????????????????????????????????з??????????????????????л????Щ?????????????

??????????????????SQLServer??????????????????????????????????????????????????????????????????????

?????????????

??????????????????????????/?????????????

??????????????????????????????????????1?????????????????????????

?????????????????????

????????????????SQLServer?????????????????????????????????SELECT?????????????????????????????

????1????????????????????

????2????????????????????

?????????????

??????????????????????β??????????????????????

SELECT  CASE WHEN DATABASEPROPERTYEX('master'?? 'IsAutoCreateStatistics') = 1
             THEN 'Yes'
             ELSE 'No'
        END AS 'IsAutoCreateStatistics?' ??
        CASE WHEN DATABASEPROPERTYEX('Master'?? 'IsAutoUpdateStatistics') = 1
             THEN 'Yes'
             ELSE 'No'
        END AS 'IsAutoUpdateStatistics?' ??
        CASE WHEN DATABASEPROPERTYEX('Master'?? 'Is_Auto_Update_stats_async_on') = 1
             THEN 'Yes'
             ELSE 'No'
        END AS 'IsAutoUpdateStatsaAyncOn?'
GO

???????????????????where????е??????????????????????

SELECT  object_id ??

        OBJECT_NAME(object_id) AS TableName ??

        name AS StatisticsName ??

        auto_created

FROM    sys.stats

--where object_id=OBJECT_ID('Sales.SalesOrderHeader')

ORDER BY object_id DESC

GO