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
Convert function.

SQL SERVER – Simple Explanation of AT TIME ZONE Feature

September 25, 2017
Pinal Dave
SQL Tips and Tricks
SQL DateTime, SQL Function, SQL Scripts, SQL Server

The AT TIME ZONE feature arrived in SQL Server 2016. Here is a simple two-step example that converts US East Coast time to West Coast time.

Read More
Convert Decimal to Time Format in String.

SQL SERVER – Convert Decimal to Time Format in String

September 13, 2017
Pinal Dave
SQL Tips and Tricks
SQL Datatype, SQL DateTime, SQL Function, SQL Scripts, SQL Server, SQL String

A very strange question I received the other day in an email about how to convert decimal to time format string.

Read More
Removing duplicate chars from string.

SQL SERVER – Remove Duplicate Chars From String – Part 2

September 11, 2017
Pinal Dave
SQL Tips and Tricks
SQL Function, SQL Scripts, SQL Server, SQL String

My earlier UDF used a WHILE loop to remove duplicate characters. Here is another way to Remove Duplicate chars from a string using a tally number table.

Read More
How to Insert Line Break in SQL Server String?

How to Insert Line Break in SQL Server String? – Interview Question of the Week #139

September 10, 2017
Pinal Dave
SQL Interview Questions and Answers
SQL Function, SQL Scripts, SQL Server, SQL String

How do you insert a Line Break in a SQL Server string? Just press Enter inside the string, and switch SSMS results to text to see it. Here is how it works.

Read More
ISDATE Function Limitation Header.

What is the Biggest Limitation of ISDATE() Function? – Interview Question of the Week #137

August 27, 2017
Pinal Dave
SQL Interview Questions and Answers
SQL DateTime, SQL Function, SQL Server

Why does ISDATE(‘6666-04-30’) return 1 but ISDATE(‘1111-04-30’) return 0? Here are what I see as the two biggest limitations of the ISDATE() function.

Read More
Write Shortest Code Zero.

SQL SERVER – Puzzle – Write a Shortest Code to Produce Zero

August 24, 2017
Pinal Dave
SQL Puzzle
SQL Function, SQL Scripts, SQL Server

A puzzle: write the shortest code that produces zero without numbers, arithmetic, the digit 0 or LEN(). I show one valid answer; can you find another?

Read More
SQL Server query window.

SQL SERVER – Learning DATEDIFF_BIG Function in SQL Server 2016

August 23, 2017
Pinal Dave
SQL Tips and Tricks
SQL DateTime, SQL Function, SQL Scripts, SQL Server

DATEDIFF returns INT and overflows with Msg 535 on large ranges. SQL Server 2016 adds DATEDIFF_BIG, which returns BIGINT. Here is a simple example.

Read More
Previous 1 … 13 14 15 16 17 18 19 … 62 Next
  • Books
  • Testimonials
  • Privacy Policy

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