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
An overfull piggy bank with coins stuck in its slot, a larger empty red one beside it

Checking IDENTITY Columns Before They Run Out of Numbers

February 20, 2009
Pinal Dave
SQL Tips and Tricks
DBA, SQL Datatype, SQL Identity, SQL Scripts

Check IDENTITY columns for their current value, type limit and remaining range, including descending increments, before inserts fail.

Read More
A hand deals plain counters among three cups, each already holding one red counter.

Assigning Rows Round-Robin to Workers With ROW_NUMBER

February 19, 2009
Pinal Dave
SQL Tips and Tricks
Ranking Functions, SQL Scripts, Temp Table

Number the tasks, number the workers, match them with a remainder. A fair queue in one query, and the two shortcuts that quietly break it.

Read More
Movers measuring a narrow doorway before carrying a red sofa through

Reviewing a Table Change Script Before It Locks Production

February 18, 2009
Pinal Dave
SQL Tips and Tricks
DBA, SQL Lock, SQL Server, SQL Table Operation

Review a table change script for schema locks, data rewrites, supported online options, backfill batches, and a tested rollback.

Read More
SQLOutlook, SQL Server, database, file locations.

SQL SERVER – Find Current Location of Data and Log File of All the Database

February 17, 2009
Pinal Dave
SQL Tips and Tricks
SQL Backup and Restore, SQL Scripts, SQL Server Security, SQL System Table

A one line query on sys.master_files that shows the current data and log file location for all databases, handy when cleaning up old .mdf and .ldf files.

Read More
SQL SERVER - List All Server Wide Configurations Values

SQL SERVER – List All Server Wide Configurations Values

February 16, 2009
Pinal Dave
SQL Tips and Tricks
SQL Scripts, SQL Server, SQL Stored Procedure, SQL System Table

I forgot the syntax to check the two digit year cutoff, so I listed all Server Wide Configurations with sys.configurations. A small script worth saving.

Read More
SQL SERVER - Reasons to Backup Master Database - Why Should Master Database Backedup

SQL SERVER – Reasons to Backup Master Database – Why Should Master Database Backedup

February 15, 2009
Pinal Dave
SQL Tips and Tricks
Best Practices, SQL Backup and Restore, SQL Data Storage, SQL Server Security, SQL Utility

Why should you backup master database? It holds all logins, system configuration and the details SQL Server needs to reach every other database.

Read More
SQLCMD command window with a query.

SQL SERVER – Restore Master Database – An Easy Solution

February 14, 2009
Pinal Dave
SQL Tips and Tricks
SQL Backup and Restore, SQL Scripts, SQL Server Security, SQL Utility

A two step easy way to restore master database: start SQL Server in single user mode, then restore from a full backup of master. No full backup, no restore.

Read More
Previous 1 … 714 715 716 717 718 719 720 … 841 Next
  • Books
  • Testimonials
  • Privacy Policy

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