CREATE STATISTICS (SQL Server Compact)
Creates a histogram (a bar chart) of the supplied table and index or indices.
The following example creates a histogram of the MyCustomers table and index.
CREATE TABLE MyCustomers (CustID int, CompanyName nvarchar(50)); CREATE UNIQUE INDEX idxCustId ON MyCustomers (CustId); DROP STATISTICS ON MyCustomers.idxCustId; CREATE STATISTICS ON MyCustomers.idxCustId WITH FULLSCAN, NORECOMPUTE;