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
Two matching slate blue birdhouses on a fence post, one with a higher entry hole and no perch.

Comparing Two Database Schemas With T-SQL

January 22, 2014
Pinal Dave
SQL Tips and Tricks
Schema, SQL Scripts, SQL Server, SQL System Table

Comparing two database schemas with catalog queries exposes missing objects, changed columns, and index differences before deployment.

Read More
A pinsetter deck holds round bowling pins while a square block cannot fit its opening

Edge Constraints: Controlling Which Nodes a Graph Edge Connects

November 19, 2013
Pinal Dave
SQL Tips and Tricks
Schema, SQL Constraint and Keys, SQL Delete

An edge table with no rules accepts nonsense links. Add an edge constraint, watch the bad edge fail, and see what the constraint still does not check.

Read More
A steel connector joins one cream cord to an eyelet while a second cord remains unattached

Polymorphic Associations: Why One Column Cannot Point at Many Tables

October 15, 2013
Pinal Dave
SQL Tips and Tricks
Normalization, Schema, SQL Constraint and Keys

One column that points at many tables cannot be enforced by SQL Server. Here is the demo, the orphans it allows, and a design that says no to bad rows.

Read More
A wooden bee hotel of hollow tubes on a garden wall, each tube sealed separately, one bee landing at its own.

A Multi-Tenant Schema With a TenantId Column: Keys, Indexes and Safety

October 16, 2012
Pinal Dave
SQL Tips and Tricks
Schema, SQL Constraint and Keys, SQL Index, SQL Server, SQL Server Security

Design a multi-tenant schema with composite keys, tenant-first indexes, trusted session context, and row-level security checks.

Read More
A corridor wall half repainted, a roller resting midway

Rolling Out Database Changes Gradually

October 11, 2012
Pinal Dave
SQL Tips and Tricks
DevOps, Schema, Software Development, SQL Server

Roll out database changes gradually with expand-and-contract steps, feature flags, data checks, and a rollback path for each stage.

Read More
An open suitcase on a bed, one side empty with its straps showing and the other side packed with folded linens under a red strap.

DACPAC vs BACPAC Quiz: Which File Carries Your Data?

January 13, 2012
Pinal Dave
SQL Puzzle
Cloud Computing, Schema, SQL Backup and Restore, SQL Migration

This DACPAC vs BACPAC Quiz asks which file moves a database with its rows to Azure SQL Database. The answer is the BACPAC. A tested script shows what each file describes, and the SqlPackage commands show how to use them.

Read More
Hens filing up a ramp into a wooden coop at dusk while one small red hen wanders alone in the yard.

Counting Users, Roles and Orphans in Every Database

December 25, 2011
Pinal Dave
SQL Tips and Tricks
DBA, Schema, SQL Cursor, SQL Login, SQL Server Security

Audit counting users across databases, include roles and schema ownership, and distinguish orphaned SQL users from contained identities.

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

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