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 ring of brass keys on a hook in a corridor of wooden doors, one door ajar with light spilling out

Exploring the System Catalog With Queries

October 2, 2008
Pinal Dave
SQL Tips and Tricks
DBA, SQL Index, SQL Server, SQL System Table

Exploring the system catalog with queries reveals SQL Server objects, columns, indexes, and dependencies without relying on stale diagrams.

Read More
Gouache painting: a second towel lies loose beside it

DATETIMEOFFSETFROMPARTS: Build an Explicit Offset

October 2, 2008
Pinal Dave
SQL Tips and Tricks
SQL DateTime, SQL Function, SQL Server

DATETIMEOFFSETFROMPARTS constructs a local clock with an explicit offset. Keep both component signs consistent and validate the complete input.

Read More
A rich painting pairs handmade blue, ochre and sage tiles arranged in horizontal rows and vertical columns.

PIVOT and UNPIVOT: Aggregation, NULLs and Cross-Tab Queries

October 1, 2008
Pinal Dave
SQL Tips and Tricks
PIVOT and UNPIVOT, SQL Group By, SQL Server

PIVOT and UNPIVOT reshape SQL Server data. See a tested example, disappearing NULLs, aggregation and fixed cross-tab columns.

Read More
A figure closes red storm shutters on seaside cottage windows facing an approaching storm.

Responding to a SQL Server Security Bulletin

September 30, 2008
Pinal Dave
SQL Tips and Tricks
Cumulative Update, DBA, SQL Patch, SQL Server, SQL Server Security

A SQL Server Security Bulletin should trigger exposure checks, ordered patching, verified recovery, and a clear management update.

Read More
Water poured from a jug overflows a small espresso cup into its saucer.

Computed Column Data Types: Why the Result Type Surprises You

September 29, 2008
Pinal Dave
SQL Tips and Tricks
Computed Column, SQL Column, SQL Datatype, SQL Error Messages

Your table accepts every insert, then the report dies with an overflow error. Here is why the type is inherited and the cast that fixes it.

Read More
SQL SERVER - Renaming SP is Not Good Idea - Renaming Stored Procedure Does Not Update sys.procedures

SQL SERVER – Renaming SP is Not Good Idea – Renaming Stored Procedure Does Not Update sys.procedures

September 28, 2008
Pinal Dave
SQL Tips and Tricks
SQL Scripts, SQL Server, SQL Stored Procedure, SQL System Table

Renaming Stored Procedure objects with sp_rename looks fine, but the stored definition keeps the old name, as sp_helptext shows. A quick demo on AdventureWorks.

Read More
SQL SERVER - Puzzle - Computed Columns Datatype Explanation

SQL SERVER – Puzzle – Computed Columns Datatype Explanation

September 27, 2008
Pinal Dave
SQL Puzzle
MVP, SQL Scripts

Jacob Sebastian explains that SQL Server casts to the data type with the highest precedence. That leads to my puzzle on computed columns datatype.

Read More
SQL SERVER - Get Answer in Float When Dividing of Two Integer

SQL SERVER – Get Answer in Float When Dividing of Two Integer

September 26, 2008
Pinal Dave
SQL Tips and Tricks
SQL Function, SQL Scripts

Dividing one integer by another in SQL Server returns an integer. Use CAST or CONVERT to get the answer in float, with decimals, as this example shows.

Read More
SQL SERVER - Guidelines and Coding Standards Complete List Download

SQL SERVER – Guidelines and Coding Standards Complete List Download

September 25, 2008
Pinal Dave
SQL Tips and Tricks
Best Practices, Data Warehousing, Database, DBA, SQL Coding Standards, SQL Constraint and Keys, SQL Cursor, SQL Data Storage, SQL Download, SQL Function, SQL Index, SQL Joins, SQL Scripts, SQL Server Security, SQL Stored Procedure, SQL Trigger, SQL Utility

My coding standards complete list for SQL Server, cut to what people follow: naming, formatting, and the rules that prevent real bugs.

Read More
SQL SERVER - Guidelines and Coding Standards Part - 2

SQL SERVER – Guidelines and Coding Standards Part – 2

September 24, 2008
Pinal Dave
SQL Performance
Best Practices, Database, Software Development, SQL Coding Standards, SQL Scripts, SQL Stored Procedure

Part 2 of my Guidelines and Coding Standards: nest single quotes, add parentheses for readability, use IF EXISTS with SELECT 1, and avoid the SP_ prefix.

Read More
Previous 1 … 515 516 517 518 519 520 521 … 590 Next
  • Books
  • Testimonials
  • Privacy Policy

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