statistics

How to Think Like the SQL Server Engine: Using Statistics to Build Query Plans

  • Article

Every index has a matching statistic with the same name, and each statistic is a single 8KB page of metadata that describes the contents of your indexes. Stats have been around (and been mostly the same) for forever, so this is one of the places where SQL Server’s documentation really shines: Books Online has a ton of information about statistics. You honestly don’t need to know most of that – but if you wanna make a living performance tuning, there’s a ton of great stuff in there.

2019-11-21

Customizing Statistics Histogram in SQL Server 2019

  • Article

The use of statistics in SQL Server is tightly embedded in the query optimizer and query processor. The creation and maintenance of statistics is usually handled by the SQL Server engine, though many DBAs and developers know that periodically we might need to update those statistics to ensure good performance of queries. SQL Server 2019 gives us more options.

2019-04-01

3 reads

Statistics in SQL: Student’s t-test

  • Article

Many undergraduates have misunderstood the name 'Students' in the t-test to imply that it was designed as a simple test suitable for students. In fact it was William Sealy Gosset, an Englishman publishing under the pseudonym Student, who developed the t-test and t distribution in 1908, as a way of making confident predictions from small sample sizes of normally-distributed variables. As Gosset's employer was Guinness, the brewer, Phil Factor takes a sober view of calculating it in SQL.

2017-10-12

3,767 reads

Statistics in SQL: Simple Linear Regressions

  • Article

Although linear regressions can get complicated, most jobs involving the plotting of a trendline are easy. Simple Linear Regression is handy for the SQL Programmer in making a prediction of a linear trend and giving a figure for the level probability for the prediction, and what is more, they are easy to do with the aggregation that is built into SQL.

2017-06-22

5,131 reads

Statistics in SQL: Kendall’s Tau rank correlation

  • Article

Statistical calculations in SQL are often perfectly easy to do. SQL was designed to be a natural fit for calculating correlation, regression and variance on large quantities of data. It just isn't always immediately obvious how. In the second of a series of articles, Phil factor shows how calculating a non-parametric correlation via Kendall's Tau or Spearman's Rho can be stress-free.

2017-06-20

3,513 reads

Blogs

CRM Data Source Connection Error

By

This article takes us to the edge with a couple of CRM related errors...

SSAS Tabular – Process Add memory consumption

By

For me it’s a bit surprising how little information can be found regarding the...

Our SQL Server 2019 Administration Inside Out Fun Author Survey

By

SQL Server 2019 Administration Inside Out Honored again to be leading the talented SQL Server...

Read the latest Blogs

Forums

How to create dynamic sql based on optional values from temp ?

By ahmed_elbarbary.2010

I have #TempMaster temp table have 3 fields with optional values on 3 fields...

connection timeout on a previously established connection

By Syed_SQLDBA

I have been seeing this in the error log file but can't seem to...

Roles and Permissions

By Admingod

QA is requesting for permission to execute store proc's in database against UAT to...

Visit the forum

Ask SSC

SQL Server Q&A from the SQLServerCentral community

Get answers