How to convert text to integer with CAST and CONVERT, whether they fail on alpha-numeric values (yes), and how to pull only the numbers from a string.
SQL SERVER – Definition, Comparison and Difference between HAVING and WHERE Clause
I asked every candidate the difference between HAVING and WHERE clause, and none got it right. HAVING filters groups, while WHERE filters individual rows.
SQL SERVER – Recompile All The Stored Procedure on Specific Table
After BCP or DTS mass inserts, stored procedures can slow down. I use sp_recompile to recompile all the stored procedure on a table, or just one procedure.
How to Read a SQL Server Error Message
Read a SQL Server error message by separating its number, severity, state, procedure, and line, then preserve the context needed to investigate.
Normalization Jokes and the Normal Forms They Make Fun Of
Normalization jokes are funny because they are true. Here are the classics in my own words, and the first three normal forms they poke fun at.
SQL SERVER – Retrieve – Select Only Date Part From DateTime – Best Practice
Selecting the date part and formatting it are different tasks. I keep typed dates for calculations and text for display.







