Tag: sql functions

T-SQL Regular Expressions: SUBSTRING, PATINDEX and CHARINDEX

Languages & Coding, T-SQL

In my previous article about T-SQL regular expressions, I have explained the LIKE operator, its...
Read More

Transact-SQL: Working With Strings

Languages & Coding, T-SQL

Microsoft SQL Server has many built-in functions that can be used to format the output and represents it in the desired format. In this...
Read More

Calculate the median by using Transact SQL

Languages & Coding, T-SQL

The statistical median is the value which separates a dataset into halves – one comprises greater values, and the other comprises...
Read More

Several Ways to Insert Split Delimited Strings in a Column

Database development, Tables

In this article, I will demonstrate several ways to split the delimited string and insert it in...
Read More

How to Properly Use the T-SQL IsNumeric Function

Languages & Coding, T-SQL

This article is focused on the T-SQL (Transact-SQL) IsNumeric function and its proper use in day-to-day SQL scripting tasks. We will also...
Read More

T-SQL Datetime Data Type

Database administration, Work with data

Introduction Data types are attributes that specify the kind of data that objects such as columns, local variables, expressions, and...
Read More

Concatenation in Transact-SQL

Languages & Coding, Statements, T-SQL

Introduction Assuming you maintain a table containing customer data, and your boss asks you to send...
Read More

Dealing with NULLs in SQL Server

Database administration, Work with data

What is NULL? NULL or the NULL marker is the way we represent an unknown value in SQL, by SQL I am referring to the standard Structured...
Read More

Using DATEADD, DATEDIFF and DATEPART T-SQL Functions in Simple Terms

Database development, Statements • 11 Comments

This article focuses on developing a basic understanding of how to use one of the most common Transact-SQL date functions: DATEADD,...
Read More

Understanding GROUPING and GROUPING_ID Functions in SQL Server

Database development, Statements

The ROLLUP and CUBE operators are used to return results aggregated by the columns in the GROUP BY...
Read More
Close