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 selected compartmented drawer is inspected with a brass measuring tool while other drawers stay closed.

SQL Server – How to Get Column Names From a Specific Table?

June 29, 2017
Pinal Dave
SQL Tips and Tricks
SQL Scripts, SQL Server, SQL System Table

I get column names from schema-qualified table metadata. Catalog views help when I also need SQL Server-specific details.

Read More
Clay ocarina openings beside their distinct matching plugs

Magic Numbers in Code: Replacing Status Codes With a Lookup Table

June 20, 2017
Pinal Dave
SQL Tips and Tricks
SQL System Table, SQL Table Operation, Table Partitioning, Temp Table

Nobody remembers what the 3 means. Give each status code an approved name, let the database enforce it, and leave your data alone.

Read More
SQL Server DB Size.

SQL SERVER – Simple Query to List Size of the Table with Row Counts

May 25, 2017
Pinal Dave
SQL Tips and Tricks
SQL Scripts, SQL Server, SQL System Table

A simple query I run at customer sites to list every table with its size in MB and Row Counts, including used and unused space.

Read More
SQL Server query properties.

SQL SERVER – How to Find Row Count of Every Table in Database Efficiently?

May 24, 2017
Pinal Dave
SQL Tips and Tricks
SQL DMV, SQL Scripts, SQL Server, SQL System Table

How do you find the row count of every table in a database without a cursor? An interview question, answered with a fast query instead of a loop.

Read More
Current peony bloom beside retained fallen petal layers

Temporal History Queries: Indexing the History Table for Speed

March 1, 2017
Pinal Dave
SQL Performance
SQL System Table, SQL Table Operation, Table Partitioning, Temp Table

Your current table is tiny, but the AS OF question hides in the history table. See the reads before and after a key-first index, and what it costs.

Read More
Title card: Error 17113: Error Opening master.mdf at Startup

SQL SERVER – Error 17113, Severity: 16 – Error Occurred While Opening File ‘master.mdf’ to Obtain Configuration Information at Startup

February 21, 2017
Pinal Dave
SQL Tips and Tricks
SQL Error Messages, SQL Scripts, SQL Server, SQL System Table, System Database

I broke my own SQL Server by editing startup parameters. Here is how the ERRORLOG helped me fix error 17113, error opening master.mdf at startup.

Read More
Incense censer retaining earlier ash beside an older fragment and a fresh coil

Currency Rates by Effective Date: Designing the Lookup Table

January 21, 2017
Pinal Dave
SQL Tips and Tricks
SQL System Table, SQL Table Operation, Table Partitioning, Temp Table

Why did last quarter’s invoices change overnight? Probably because the rate table had no dates. Here is a lookup that remembers.

Read More
Previous 1 2 3 4 5 6 7 8 … 18 Next
  • Books
  • Testimonials
  • Privacy Policy

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