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 of four nested bowls on a kitchen counter with the smallest center bowl painted red

Order of Operations in SQL Server: How PEMDAS Works in T-SQL

September 25, 2012
Pinal Dave
SQL Tips and Tricks
Mathematics, SQL Operator, SQL Scripts, SQL Server

The order of operations in SQL Server follows PEMDAS, so 6/2*(1+2) returns 9. This post walks through the precedence rules with tested queries. It also covers integer division, the negative number trap and AND before OR.

Read More
SQL SERVER - Excel Losing Decimal Values When Value Pasted from SSMS ResultSet

SQL SERVER – Excel Losing Decimal Values When Value Pasted from SSMS ResultSet

September 24, 2012
Pinal Dave
SQL Tips and Tricks
Excel, SQL Server, SQL Server Management Studio, SQL Utility

I often get questions that how to fix the issue where excel loses decimal values when values are pasted from SSMS Resultset. 

Read More
A model ship floats in a long indoor water tank as small waves roll toward it from the far end.

Keeping a Patch Test Environment Honest

September 23, 2012
Pinal Dave
SQL Tips and Tricks
SQL Backup and Restore, SQL Patch, SQL Server, SQL Server Configuration, Testing

A Patch Test Environment must match production data, settings, jobs, and versions closely enough to reveal real patch risks.

Read More
Several separate cabinets expose their fittings for inspection beside a plain marker and lens.

SQL SERVER – Validating Unique Column Name Across Whole Database

September 22, 2012
Pinal Dave
SQL Tips and Tricks
SQL Scripts, SQL Server, SQL System Table

A Unique Column Name check lists existing matches across visible database metadata. I use it as an inspection, not an enforcement guarantee.

Read More
SQL SERVER - Replace a Column Name in Multiple Stored Procedure All Together

SQL SERVER – Replace a Column Name in Multiple Stored Procedure All Together

September 21, 2012
Pinal Dave
SQL Tips and Tricks
SQL Server, SQL Server Management Studio, SQL Stored Procedure

A beginner on a development server asked how to replace a column name in Multiple Stored Procedure code all together. Here is the quick way I suggest.

Read More
A tall boot beside a small open shoebox that holds only a small red paper star instead of the boot.

Why CAST to a Short VARCHAR Returns a Star Instead of an Error

September 20, 2012
Pinal Dave
SQL Tips and Tricks
SQL Datatype, SQL Function, SQL Server, SQL String

Understand why a short VARCHAR returns a star for an integer, compare Unicode errors and string truncation, and size conversions safely.

Read More
SQL SERVER - SQL Server Statistics Name and Index Creation

SQL SERVER – SQL Server Statistics Name and Index Creation

September 17, 2012
Pinal Dave
SQL Performance
SQL Error Messages, SQL Index, SQL Scripts, SQL Server, SQL Statistics

Guest author Sandip hit Msg 1913 while creating an index, because an index or statistics with that name already existed. A lesson on statistics name and index creation.

Read More
Previous 1 … 290 291 292 293 294 295 296 … 420 Next
  • Books
  • Testimonials
  • Privacy Policy

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