This month's discount Comprehensive Database Performance Health Check · Testimonials
SQLAuthority with Pinal Dave
Home
  • Consulting
    • Health Check
  • Free Videos
  • All Articles
    • AI
    • SQL Performance
    • SQL Tips and Tricks
    • Interview Questions and Answers
    • SQL Puzzle
    • SQL Video
    • SQLAuthority News
    • Personal
  • Books
  • Consulting
Vacated clay recesses retain small traces beside a cleanup brush and an intact tray of finished tiles.

SQL SERVER – What Are Ghost Records and How to Clean Them Up?

September 28, 2017
Pinal Dave
SQL Tips and Tricks
SQL Backup and Restore, SQL Scripts, SQL Server

Ghost Records are logically deleted index records waiting for physical cleanup. I investigate their context before recommending an intervention.

Read More
A terraced vineyard on a hillside, flat steps of different widths roughly following the slope

Querying a Histogram With sys.dm_db_stats_histogram Instead of DBCC

September 27, 2017
Pinal Dave
SQL Performance
SQL DMV, SQL Index, SQL Server, SQL Statistics

Query sys.dm_db_stats_histogram to inspect statistics steps, compare stored estimates with data, and identify values beyond the last step.

Read More
SQL Server query with 2 tables.

SQL SERVER – Select Unique Data From a Column Exist in Two Different Table

September 26, 2017
Pinal Dave
SQL Puzzle
SQL Scripts, SQL Server, SQL Union clause

A reader wanted to Select Unique Data from a column in two tables, keeping only values found in just one of them. Here is the query that does it.

Read More
Convert function.

SQL SERVER – Simple Explanation of AT TIME ZONE Feature

September 25, 2017
Pinal Dave
SQL Tips and Tricks
SQL DateTime, SQL Function, SQL Scripts, SQL Server

The AT TIME ZONE feature arrived in SQL Server 2016. Here is a simple two-step example that converts US East Coast time to West Coast time.

Read More
One smoking lantern is separated while the other session lanterns stay lit

How to Kill User Sessions (SPID) in SQL Server? – Interview Question of the Week #141

September 24, 2017
Pinal Dave
SQL Interview Questions and Answers
SQL Scripts, SQL Server

How do you Kill User Sessions (SPID) in SQL Server? First ask why you want to, since killing busy sessions rarely helps. Then here is the script.

Read More
Floppy Disk Drive (A:).

SQL SERVER – The Operating System Returned the Error 21(The Device is Not Ready.) While Attempting ‘GetDiskFreeSpace’ on ‘A:\’

September 23, 2017
Pinal Dave
SQL Tips and Tricks
SQL Error Messages, SQL Scripts, SQL Server

While testing SQL Server 2017, I found Error 21 (the device is not ready) in the ERRORLOG for GetDiskFreeSpace on drive A. Here is why it shows up.

Read More
Drive path query window.

SQL SERVER – New DMV in SQL Server 2017 – sys.dm_os_enumerate_fixed_drives. A Replacement of xp_fixeddrives

September 22, 2017
Pinal Dave
SQL Tips and Tricks
SQL Scripts, SQL Server, SQL Server 2017, SQL Stored Procedure

SQL Server 2017 adds sys.dm_os_enumerate_fixed_drives, a new DMV that shows free space on each drive and replaces xp_fixeddrives. Here is the query I use.

Read More
Previous 1 … 149 150 151 152 153 154 155 … 416 Next
  • Books
  • Testimonials
  • Privacy Policy

© 2006 – 2026 All rights reserved. pinal @ SQLAuthority.com