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
A combined glass-cutting tool beside separate scoring and breaking tools

MERGE Performance for Large Upserts: UPDATE Then INSERT Instead

December 21, 2012
Pinal Dave
SQL Performance
SQL Performance, SQL Scripts, SQL Server

Is MERGE really slow, or did the rewrite just run on a quiet night? Here is a fair test you can run yourself.

Read More
A cork borer and extracted core beside intact and fully opened cork stoppers

SAMPLED vs DETAILED: Running index_physical_stats Safely

November 26, 2012
Pinal Dave
SQL Performance
SQL Index, SQL Performance, SQL Server

A misspelled table name quietly turns into a scan of everything. Here is the guard, and a fair comparison of the three scan modes on one small index.

Read More
Three apple halves on a chopping board, going from freshly cut white to tan to brown, beside a paring knife

Time Ago Labels: Showing ‘5 Minutes Ago’ From a Timestamp

October 6, 2012
Pinal Dave
SQL Tips and Tricks
Best Practices, SQL Performance, SQL Server

Learn time ago labels in SQL Server with practical examples, clear checks, common traps, and guidance for your own database.

Read More
A gardener lifting white frost covers one by one along a vegetable row on a frosty morning.

SARGable Date Filters: Stop Wrapping Columns in Functions

October 5, 2012
Pinal Dave
SQL Performance
SQL DateTime, SQL Function, SQL Index, SQL Performance, SQL Server

Write SARGable date filters as half-open ranges for years, months, days, and rolling windows, then compare plans and logical reads.

Read More
A pasta roller holds fixed rollers while dough must pass through successive connected stages

INNER HASH JOIN: Why a Table Join Hint Also Fixes Join Order

August 11, 2012
Pinal Dave
SQL Performance
Execution Plan, Query Hint, SQL Joins, SQL Performance

A join hint in the FROM clause quietly fixes the join order. I show the warning, three plans side by side, and the softer query-level alternative.

Read More
A conveyor belt of identical parcels beside a single hand trolley carrying one parcel

What Is a Cursor in SQL Server, and When to Avoid One

July 31, 2012
Pinal Dave
SQL Performance
Best Practices, SQL Performance, SQL Scripts, SQL Server

A cursor in SQL Server took 260 milliseconds where one SELECT took 4. Why the gap exists, how to turn a loop back into a set, and the three cases where a cursor really is the right answer.

Read More
A hand on a frosty windowsill with a red thread tied around one finger, snow and early snowdrops outside

Upcoming Birthdays in the Next 30 Days With T-SQL

July 30, 2012
Pinal Dave
SQL Tips and Tricks
Best Practices, SQL Performance, SQL Server

Find upcoming birthdays with T-SQL across year boundaries, choose a February 29 policy, and build a clear next-30-days list.

Read More
Previous 1 … 37 38 39 40 41 42 43 … 54 Next
  • Books
  • Testimonials
  • Privacy Policy

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