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
Execution time statistics.

SQL SERVER – Retrieve – Select Only Date Part From DateTime – Best Practice – Part 2

October 18, 2008
Pinal Dave
SQL Performance
Best Practices, SQL DateTime, SQL Function, SQL Scripts

Which way to select only date part from DATETIME is faster? After more tests on large tables, I now suggest the DATEADD and DATEDIFF method over CONVERT.

Read More
SQL SERVER - Downgrade Database to Previous Version

SQL SERVER – Downgrade Database to Previous Version

October 16, 2008
Pinal Dave
SQL Performance
Database, Software Development

Can you downgrade database files from SQL Server 2005 to 2000? No tool does it. Install the old version, recreate the schema and move the data yourself.

Read More
UNION result with all rows.

SQL SERVER – Introduction and Example of UNION and UNION ALL

October 15, 2008
Pinal Dave
SQL Performance
SQL Joins, SQL Scripts, SQL Union clause

A simple example of UNION and UNION ALL with two table variables. UNION removes the duplicate rows, while UNION ALL keeps every row from both tables.

Read More
SQL SERVER - 2008 - Enhenced TRIM() Function - Remove Trailing Spaces, Leading Spaces, White Space, Tabs, Carriage Returns, Line Feeds

SQL SERVER – 2008 – Enhenced TRIM() Function – Remove Trailing Spaces, Leading Spaces, White Space, Tabs, Carriage Returns, Line Feeds

October 10, 2008
Pinal Dave
SQL Performance
SQL Function, SQL Scripts, SQL String, SQL Utility

Need to remove trailing spaces, leading spaces, tabs, carriage returns and line feeds? Here is an enhanced TRIM function built from a script by Russ and Erik.

Read More
SQL Server execution plan.

SQL SERVER – 2008 – Find If Index is Being Used in Database

October 3, 2008
Pinal Dave
SQL Performance
SQL DMV, SQL Index, SQL Scripts

How do you find if an index is being used in your database? My quick script checks sys.dm_db_index_usage_stats, so you can drop unused indexes safely.

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
SQL SERVER - Guidelines and Coding Standards Part - 1

SQL SERVER – Guidelines and Coding Standards Part 1

September 23, 2008
Pinal Dave
SQL Performance
Best Practices, Database, Software Development, SQL Coding Standards, SQL Constraint and Keys, SQL Index, SQL Joins, SQL Scripts, SQL Stored Procedure

Guidelines and Coding Standards Part 1: Pascal naming for tables, and naming patterns for stored procedures, triggers, indexes and keys.

Read More
Previous 1 … 98 99 100 101 102 103 104 … 120 Next
  • Books
  • Testimonials
  • Privacy Policy

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