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
Temp Table in

Dropping Temp Table in Stored Procedure – SQL in Sixty Seconds #124

September 22, 2020
Pinal Dave
SQL Video
SQL in Sixty Seconds, SQL Performance, SQL Scripts, SQL Server, SQL Stored Procedure, SQL TempDB, Temp Table

Is dropping temp table in stored procedure code really needed? In this SQL in Sixty Seconds video, I compare two procedures to show what happens.

Read More
A folded paper shelter stands beside a permanent wooden house on a workbench

What is Temp Stored Procedures? – Interview Question of the Week #294

September 20, 2020
Pinal Dave
SQL Interview Questions and Answers
SQL Scripts, SQL Server, SQL Stored Procedure, SQL TempDB, Temp Table

Temp stored procedures are the SPthat are created with the help of the # at the beginning of the name and only available until the SQL Server restarts.

Read More
Table Variable Stored

Where are Table Variables Stored? – SQL in Sixty Seconds #095

August 6, 2020
Pinal Dave
SQL Video
SQL in Sixty Seconds, SQL Memory, SQL Performance, SQL Scripts, SQL Server, SQL Variable, Temp Table

A very popular question we will answer today Where are Table Variables Stored? Recently I have posted a few videos on my YouTube Channel,

Read More
A ravioli press fitting different fillings into separately formed pasta parcels

Survey Answers: A Table Design for Questions and Responses

April 10, 2020
Pinal Dave
SQL Tips and Tricks
SQL System Table, SQL Table Operation, Table Partitioning, Temp Table

Store survey answers as typed rows instead of one column per question. Then break the design on purpose to see what it blocks and what it cannot.

Read More
Gouache painting of a vermilion template board beside a pile of identical pieces cut from it on a workbench

KEEP PLAN Hint: Cut Temp Table Recompiles in SQL Server

March 11, 2020
Pinal Dave
SQL Performance
Query Hint, Recompile, SQL TempDB, Temp Table

The KEEP PLAN hint gives a temp table the same recompile threshold as a permanent table. This post counts statistics recompiles with Extended Events for a plain query, a KEEP PLAN query and a KEEPFIXED PLAN query. It shows where the hint helps, where it does nothing and what the stronger hint costs.

Read More
Gouache painting of a heap of pears beside a grey wooden crate, a blue crate and an open vermilion crate

SELECT INTO Table Variable: Why It Fails and What to Use

March 2, 2020
Pinal Dave
SQL Tips and Tricks
SQL Scripts, SQL Table Operation, SQL Variable, Temp Table

SELECT INTO table variable fails with Msg 102 because SELECT INTO creates its target table and a table variable must be declared first. This post shows two working fixes, a declared table variable and a temp table. It also compares them on rollback, dynamic SQL and row estimates.

Read More
A pottery roller leaves patterned impressions in clay tiles, with one tile showing a different gap.

Detecting Changed Rows With a Row Hash

February 29, 2020
Pinal Dave
SQL Tips and Tricks
Batch, ETL, SQL Function, Temp Table

Compare one fingerprint instead of twenty columns. I show a safe HASHBYTES recipe, the NULL trap that fools CONCAT_WS, and a load that touches only the rows that changed.

Read More
Previous 1 2 3 4 5 … 11 Next
  • Books
  • Testimonials
  • Privacy Policy

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