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
Gouache painting of a fresh pattern sheet pinned on cloth with vermilion scissors beside a pile of crumpled old patterns

OPTION (RECOMPILE) Hint: When a Fresh Plan Pays Off

December 31, 2019
Pinal Dave
SQL Tips and Tricks
Parameter Sniffing, Query Hint, Recompile, SQL Scripts, SQL Stored Procedure

The OPTION (RECOMPILE) hint tells SQL Server to build a new plan every time a statement runs. This post measures the page reads it saves on skewed data, the compile cost it adds, the filtered index it unlocks, and how to apply it to one statement of a procedure.

Read More
Gouache painting of a brass tap with a vermilion wheel feeding a trough that runs past a row of young apple trees

Database Scoped Configuration: Turn Off Parameter Sniffing

December 30, 2019
Pinal Dave
SQL Performance
Parameter Sniffing, SQL Scripts, SQL Server Configuration, SQL Stored Procedure

A database scoped configuration lets you turn off parameter sniffing for one database with a single statement. This post measures a procedure with the setting on and off, shows that the change clears the cached plans of the database, and explains what the switch does not fix.

Read More
Two identical carved wooden knights show an original alongside its faithful duplicate

How to Copy Files in SQL Server? – Interview Question of the Week #257

December 29, 2019
Pinal Dave
SQL Interview Questions and Answers
SQL Command, SQL Scripts, SQL Server, SQL Stored Procedure

Question: How to Copy Files in SQL Server?

Answer: SQL Server 2019 has very interesting features that can make a life of DBA’s and Developers very easy.

Read More
A hand holding a tulip bulb, paused above a spot where a shoot already grows in a garden bed.

Loading Only New Rows: INSERT SELECT With NOT EXISTS

December 25, 2019
Pinal Dave
SQL Tips and Tricks
Duplicate Records, SQL Constraint and Keys, SQL Scripts, SQL Server

Make loading only new rows repeatable with NOT EXISTS, EXCEPT, source deduplication, and a unique key that protects the destination.

Read More
A checkered cloth spread on market cobblestones as a makeshift stall, with a short row of lemons and one blood orange.

The VALUES Table Constructor: Using a List as a Table

December 24, 2019
Pinal Dave
SQL Tips and Tricks
SQL Joins, SQL Scripts, SQL Server, SQL Table Operation, Temp Table

Use a VALUES table constructor for inline mappings and joins, understand the INSERT row limit, and move larger reusable lists into tables.

Read More
A cat with a new collar remains the same cat, beside its old collar

Can Admin Rename SA Account in SQL Server? – Interview Question of the Week #256

December 22, 2019
Pinal Dave
SQL Interview Questions and Answers
SQL Login, SQL Scripts, SQL Server, SQL Server Security

Question: Can Admin Rename SA Account in SQL Server?

Answer: Yes, of course. The syntax for to rename SA account is very simple:

Read More
Illustrated cover: OPTIMIZE FOR UNKNOWN

SQL SERVER – Parameter Sniffing and OPTIMIZE FOR UNKNOWN

December 21, 2019
Pinal Dave
SQL Tips and Tricks
Parameter Sniffing, SQL Performance, SQL Scripts, SQL Server, SQL Stored Procedure

I consider myself fortunate that I receive a follow-up question from my blog posts. Let’s discuss Parameter Sniffing and OPTIMIZE FOR UNKNOWN.

Read More
Previous 1 … 51 52 53 54 55 56 57 … 365 Next
  • Books
  • Testimonials
  • Privacy Policy

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