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
Over and partion by query results.

SQL SERVER – Adding Values WITH OVER and PARTITION BY

June 16, 2018
Pinal Dave
SQL Tips and Tricks
Ranking Functions, SQL Function, SQL Order By, SQL Scripts, SQL Server

How do you sum values for each group without GROUP BY and still keep every row? Here is how SUM with OVER and PARTITION BY answers a reader’s question.

Read More
Gouache painting of a wooden loom with many pale threads and one vermilion thread through the middle

Optimal Value for Max Worker Threads in SQL Server

June 15, 2018
Pinal Dave
SQL Performance
SQL CPU, SQL DMV, SQL Server

The optimal value for Max Worker Threads is the default, 0, which tells SQL Server to calculate the limit from the number of logical processors. This post shows how to read the real limit, how the formula works, and which wait and queue counters prove a thread shortage before you change anything.

Read More
SQL SERVER - How to DELETE Multiple Table Together Via SQL Server Management Studio (SSMS)?

SQL SERVER – How to DELETE Multiple Table Together Via SQL Server Management Studio (SSMS)?

June 14, 2018
Pinal Dave
SQL Tips and Tricks
SQL Scripts, SQL Server, SQL Server Management Studio

A DBA asked for a shortcut to drop more than one table at once in SSMS without writing T-SQL. Here are the simple steps, using just the keyboard.

Read More
SQL SERVER - Performance Comparison IN vs OR

SQL SERVER – Performance Comparison IN vs OR

June 13, 2018
Pinal Dave
SQL Performance
SQL Function, SQL Operator, SQL Server

Which query runs faster, one with IN or one with OR? Here is my performance comparison IN vs OR on AdventureWorks, and both turn out equal.

Read More
A spring balancer supporting a linked guide between two fabric rolls

DATE_CORRELATION_OPTIMIZATION: Helping Joins on Related Dates

June 12, 2018
Pinal Dave
SQL Tips and Tricks
Best Practices, SQL Joins, SQL Server

SQL Server can learn that an order date and a ship date move together. Here is a small demo of the read savings and the trade you accept.

Read More
Illustrated cover: Implicit Conversion

SQL SERVER – How to Fix CONVERT_IMPLICIT Warnings?

June 11, 2018
Pinal Dave
SQL Performance
SQL Function, SQL Scripts, SQL Server

CONVERT_IMPLICIT warnings are one of the most common performance issues I find in health checks. Here is how to find them in your queries and how to fix them.

Read More
Several similar sparrows and one different bird gather at a feeder

How to Find Cardinality or Uniqueness for any Column? – Interview Question of the Week #177

June 10, 2018
Pinal Dave
SQL Interview Questions and Answers
SQL Index, SQL Performance, SQL Scripts, SQL Server

What is Cardinality, and how do you find it for a column? This simple script shows the percentage of unique values, using an AdventureWorks table.

Read More
Previous 1 … 119 120 121 122 123 124 125 … 420 Next
  • Books
  • Testimonials
  • Privacy Policy

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