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
Gouache painting: three long raised garden rows run away from the viewer, two planted with round cabbages and the third bare soil

XPath First Items: Parentheses Change the Selected Nodes

February 25, 2009
Pinal Dave
SQL Tips and Tricks
SQL Datatype, SQL Function, SQL Scripts

XPath first items can mean one per parent or one overall. Compare step-local [1] with a parenthesized path, including full XML and empty selections.

Read More
Two matching glass pitchers contain water at different levels on a quiet kitchen counter.

When SSMS and Your Application Return Different Results

February 22, 2009
Pinal Dave
SQL Tips and Tricks
Best Practices, Database, SQL Scripts, SQL Server

Investigate SSMS different results by comparing connections, parameters, session options, transactions, and plans against the application.

Read More
Pistachios fill six cavities of a wooden mold while two middle cavities remain empty.

Value Histograms: Counting Rows per Range Bucket in T-SQL

February 21, 2009
Pinal Dave
SQL Tips and Tricks
SQL Group By, SQL Scripts, Temp Table

Turn a column of amounts into a clear shape. Three small traps decide whether your bucket counts are true: empty buckets, uneven ranges and BETWEEN.

Read More
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
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
Previous 1 … 290 291 292 293 294 295 296 … 365 Next
  • Books
  • Testimonials
  • Privacy Policy

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