This article gives an overview of DIFFERENCE and SOUNDEX SQL Server built-in system functions. It explains how to use those functions and how do they work.
Read more »String functions
SUBSTRING, PATINDEX and CHARINDEX string functions in SQL queries
March 1, 2021In this article, we will explore SUBSTRING, PATINDEX and CHARINDEX string functions for SQL queries.
Read more »Python scripts to split and concatenate strings
April 23, 2020This article gives an overview of Python Script functions to split strings and string concatenation functions.
Read more »SQL Server functions for converting a String to a Date
February 6, 2020While working with raw data, you may frequently face date values stored as text. Converting these values to a date data type is very important since dates may be more valuable during analysis. In SQL Server, converting a string to date can be achieved in different approaches.
Read more »Using PowerShell to split a string into an array
February 5, 2020In this article, I am going to explain the PowerShell script to split a string into an array. Before I explain it, let me just give you a small introduction of the PowerShell and the PowerShell array.
Read more »Yet another bunch of SQL string functions
January 13, 2020This article is a supplement to the previously published article, An overview of SQL String Functions . This time, we will describe another bunch of SQL string functions used in SQL Server.
Read more »An overview of SQL String Functions
December 25, 2019In this article, we will try to give a brief overview of the SQL string functions used in SQL Server and we will provide some examples.
Read more »The STRING_SPLIT function in SQL Server
December 3, 2018This article will cover the STRING_SPLIT function in SQL Server including an overview and detailed usage examples.
Overview of the SQL REPLACE function
November 27, 2018In this article, I’ll show you how to find and replace data within strings. I will demonstrate how to use the function SQL REPLACE, where you look for a substring within a string, and then replace it.
Overview of SQL COUNT and COUNT_BIG in SQL Server
November 23, 2018In this article, we’ll walk-though two other important SQL aggregate function, SQL COUNT and COUNT_BIG. In the previous article of this series, we covered how to retrieve data, join tables, work with dates and times, use window functions, filter data, and much more.
Read more »Overview of the SQL Order by clause
November 23, 2018In this article, we’ll walk-through the concept of the SQL Order by clause and understand how the SQL engine works with the ordering result in a query.
Read more »SQL CAST and SQL CONVERT function overview
November 16, 2018This article is an effort to discuss SQL Cast and SQL Convert functions as a follow-up to previous articles, in which we’ve discussed several SQL tips such as SQL Date, SQL Coalesce, SQL Union, SQL Join, SQL Like, SQL String etc.
Read more »Overview of the SQL ROW_NUMBER function
November 13, 2018In this article, we’re going to discuss the SQL ROW_NUMBER function. This is a continuation of the SQL essential series. In this guide, I’ll explain what a window function is all about, and you’ll see sample examples to understand the concepts behind the SQL ROW_NUMBER function.
Read more »SQL date format Overview; DateDiff SQL function, DateAdd SQL function and more
October 31, 2018SQL date format functions like the DateDiff SQL function and DateAdd SQL Function are oft used by DBAs but many of us never took the time to fully understand these extremely useful features. For professionals just getting started with SQL Server, these functions are some of the first to become familiar with. So hopefully this article will have a little something for everyone across the skill spectrum
Read more »SQL truncate enhancement: Silent Data truncation in SQL Server 2019
October 31, 2018In this article, we’ll take a look into SQL truncate improvement in SQL Server 2019.
Data inserts and updates are a normal and regular task for the developers and database administrators as well as from the application. The source of the data can be in multiple forms as if direct insert using T-SQL, stored procedures, functions, data import from flat files, SSIS packages etc.
Read more »Querying data using the SQL Coalesce function
September 18, 2018We all know that a Null value is a field with no value. The statements that we are running daily will have to deal with Null values, especially when it comes to strings concatenation (adding strings together).
Read more »Substring function overview
September 14, 2018The requirement of data refactoring is very common and vital in data mining operations. In the previous article SQL string functions for Data Munging (Wrangling), you’ll learn the tips for getting started with SQL string functions, including the substring function for data munging with SQL Server. As we all agree that the data stored in one form sometimes require a transformation, we’ll take a look at some common functions or tasks for changing the case of a string, converting a value into a different type, trimming a value, and replacing a particular string in a field and so on.
Read more »SQL string functions for Data Munging (Wrangling)
September 13, 2018In this article, you’ll learn the tips for getting started using SQL string functions for data munging with SQL Server. In many cases, Machine learning outcomes are only as good as the data they’re built on – but the work of preparing data for analytics (that is, data wrangling) can eat up as much as 80% of your project efforts.
Read more »Understanding SQL Server’s TRY_PARSE and TRY_CONVERT functions
May 16, 2018Data conversion is one of the most fundamental tasks of any programming language. Data received from different sources is often not in the right format. For example, if you receive an XML file where age is in the string format and you want to calculate an average age for the people in the file you will need to convert age into an integer.
To make the conversion process simple, the TRY_PARSE and TRY_CONVERT functions were introduced in SQL Server 2012. Before TRY_PARSE and TRY_CONVERT, SQL Server only had the PARSE and CONVERT functions.
Read more »How to implement array-like functionality in SQL Server
January 16, 2018Introduction
I was training some Oracle DBAs in T-SQL and they asked me how to create arrays in SQL Server.
I told them that there were no arrays in SQL Server like the ones that we have in Oracle (varray). They were disappointed and asked me how was this problem handled.
Some developers asked me the same thing. Where are the arrays in SQL Server?
Read more »Top SQL string functions in SQL Server 2017
June 8, 2017SQL Server 2017 has been in the talk for its many features that simplify a developer’s life. With the previous versions, developers had to write T-SQL, or user-defined functions using temporary tables, and build complex logic, just for string manipulation. In almost every database I work with, I see many user-defined functions for string manipulation and string aggregation.
Read more »