rajeshrajesh
SSC-Addicted
Points: 425
More actions
August 9, 2010 at 9:07 am
#227616
Hi All
can any one tell me briefly what does this UPDATE STATISTICS command do on table
Please give it me very briefly
Thanks
Steve Jones - SSC Editor
SSC Guru
Points: 736270
August 9, 2010 at 9:13 am
#1204229
Do you know what statistics are? They are a sampling of the table that tries to determine what the distribution of data is for that particular column. This helps the optimizer in determining if the index will help in a query.
This command (UPDATE STATISTICS, http://msdn.microsoft.com/en-us/library/aa260645%28SQL.80%29.aspx), updates those statistics by sampling the data in the table. You can also control how much of the table is sampled.
You can view the distrubution for a column with DBCC SHOW_STATISTICS (http://msdn.microsoft.com/en-us/library/aa258821%28v=SQL.80%29.aspx)
Viewing 2 posts - 1 through 1 (of 1 total)
You must be logged in to reply to this topic. Login to reply