This article explores the useful function SQL IF statement in SQL Server.
![Rajendra Gupta](https://s33046.pcdn.co/wp-content/uploads/2022/02/rajendra_gupta.png)
![a variable in a Boolean expression and multiple IF statements](https://s33046.pcdn.co/wp-content/uploads/2019/05/a-variable-in-a-boolean-expression-and-multiple-if-624x297.png)
This article explores the useful function SQL IF statement in SQL Server.
This article explores SQL Server Concatenate operations using the SQL Plus (+) operator and SQL CONCAT function.
Read more »In a high OLTP environment, we may observe strain on CPU and IO due to frequent backups. It might include further complexity due to backup compressions. SQL Server Always On Availability groups provides the capability to perform database backups from the secondary replicas. This article explores Log backups in SQL Server Always On Availability Group.
This article explores the SQL ISNULL function to replace NULL values in expressions or table records with examples.
We use the SQL CHARINDEX function to find the position of a substring or expression in a given string. We might have a character in different positions of a string. SQL CHARINDEX returns the first position and ignores the rest of matching character positions in a string.
Read more »This article explores the DATEADD SQL function and its usage scenarios with various examples.
In this article, we will review the new SQL TRIM function in SQL Server 2017 onwards as well as providing some information on strings functions that pre-date it like LTRIM AND RTRIM.
Read more »This article explores the DATEPART SQL function and its use in writing t-SQL queries. In the previous article, SQL Convert Date Functions and Formats, we explored various data formats and convert them using SQL Convert function.
This article explains the SQL add column operation into an existing SQL table. We will also explore different examples of SQL add column operations.
Read more »This article explains to the SQL Union and vs Union All operators in SQL Server. We will also explore the difference between these two operators along with various use cases.
Read more »This article will provide a full overview, with examples of the SQL Outer join, including the full, right and left outer join as well as cover the union between SQL left and right outer joins.
Read more »This article covers the SQL INSERT INTO SELECT statement along with its syntax, examples, and use cases.
Read more »This article will cover the SQL PARTITION BY clause and, in particular, the difference with GROUP BY in a select statement. We will also explore various use cases of SQL PARTITION BY.
Read more »This article will cover the SQL ORDER BY clause including syntax, usage scenarios to sort out results in a Select statement.
Read more »This article will cover the SQL SELECT INTO statement including syntax, parameters and use with multiple tables, filegroups and a WHERE condition
Read more »In this article, we will explore various SQL Convert Date formats to use in writing SQL queries.
Read more »In this article, we will discuss and learn basics and all details about SQL Server data type converting operations and also we will review the SQL CONVERT and TRY_CONVERT built-in functions with various samples. At first, we will explain and clarify syntax of the SQL CONVERT function and then we will learn how can we make data converting process numerical and date/time data types to character data.
Read more »In 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 »Microsoft recently released a new and interactive command-line query tool for SQL Server with modern features such as auto-completion and syntax highlighting. It’s called mssql-cli and this fully open source tool works on cross-platform under the BSD-3 license.
Read more »The Bulk copy program aka bcp is the console application used to export and import data from text files to SQL Server or vice versa.
It is very popular because it is fast and easy to download.
Read more »Sqlcmd allows executing queries, T-SQL sentences and SQL Server scripts using the command line.
In the previous article How to work with the command line and Azure to automate tasks, we worked with the sqlcmd in Azure.
In this new chapter, we will show the following examples in a local SQL Server using sqlcmd:
Read more »There have always been some undocumented objects in SQL Server that are used internally by Microsoft, but they can be used by anybody that have access to it. One of those objects is a stored procedure called sp_MSforeachtable.
sp_MSforeachtable is a stored procedure that is mostly used to apply a T-SQL command to every table, iteratively, that exists in the current database.
Read more »A database recovery process is an essential requirement for database systems, It can be a tedious job and the process of recovery varies on lot of scenarios. The desire to improve recovery results has resulted in various procedures, but understood by few and prone to errors. In this article, I’ll illustrate the impact of stopping the database instance in the middle of a large transaction that was running and discuss several techniques and tools that are available for faster and successful recovery.
Read more »In a previous article on Connecting PowerShell to SQL Server I went over how you use various methods in PowerShell to connect to SQL Server. In those examples though I only touched on using the current user that is running “PowerShell.exe”. In this article I want to pick up and go over how you would use the same methods, but as a different account. I will cover using both Windows Authentication (where supported) and SQL Login authentication.
Read more »SQLCMD Mode allows creating, testing, executing SQLCMD commands or scripts in SQL Server Management Studio directly in the query editor. This option is available since SQL Server 2005.
Read more »© 2025 Quest Software Inc. ALL RIGHTS RESERVED. | GDPR | Terms of Use | Privacy