Quantcast
Channel: SQL Atoms | SQL Syntax Examples, SQL Code and SQL Tutorials » Queries
Browsing all 20 articles
Browse latest View live

How to Use the CASE Expression in SQL Server

In this tutorial you will learn how to use the CASE expression. A CASE expression is given a value that runs through the conditional logic and returns a value. Because [...]

View Article



How to Use Wild Cards in SQL Server

In this tutorial you will learn how to use wildcards in SQL Server. SQL wildcards can be used when searching for data in a database. SQL wildcards are used with the [...]

View Article

How to Use the GETDATE Function in SQL Server

This tutorial will show you how to use the GETDATE function in SQL Server. The GETDATE function retrieves the current date and time from the SQL Server at run time. [...]

View Article

How to Count Distinct Values in a Table In SQL Server

This tutorial will show how to create a query that retrieves a count of unique values in a column of a table. To make this query work, we will use [...]

View Article

How to Handle Null Values with the COALESCE Function in SQL Server

This tutorial will show how to use the COALESCE function to handle null values at run time. The COALESCE() function is used to specify how we want to treat NULL [...]

View Article


How to Calculate the Average of a Numerical Column SQL Server

This tutorial will show how to calculate the average of a numerical column with the AVG function in SQL Server. The AVG function returns the average value of a numeric column [...]

View Article

How to Round a Numeric Column to a Specified Decimal Count in SQL Server 2008 R2

This tutorial will show how to round a column to a specified decimal count. This is possible with the ROUND function. The ROUND function is used to round a numeric field [...]

View Article

How to Use the OVER Clause in SQL Server 2008 R2

This tutorial will show how to use the OVER clause in SQL Server 2008 R2. The OVER clause exposes a window of rows to certain kinds of calculations. The window [...]

View Article


How to Concatenate Non Numerical Columns in SQL Server 2008 R2

This tutorial will show how to use the string concatenation in SQL Server 2008 R2. The string concatenation uses a plus sign(+) operator to concatenate strings. It allows two strings [...]

View Article


How to Call the LEN Function on a String in SQL Server 2008 R2

This tutorial will show how to use the LEN function in SQL Server 2008 R2. The LEN function returns the number of characters in an input string, excluding trailing blanks. [...]

View Article

How to Use the CASE Expression in SQL Server

In this tutorial you will learn how to use the CASE expression. A CASE expression is given a value that runs through the conditional logic and returns a value. Because […]The post How to Use the CASE...

View Article

How to Use Wild Cards in SQL Server

In this tutorial you will learn how to use wildcards in SQL Server. SQL wildcards can be used when searching for data in a database. SQL wildcards are used with the […]The post How to Use Wild Cards in...

View Article

How to Use the GETDATE Function in SQL Server

This tutorial will show you how to use the GETDATE function in SQL Server. The GETDATE function retrieves the current date and time from the SQL Server at run time. […]The post How to Use the GETDATE...

View Article


How to Count Distinct Values in a Table In SQL Server

This tutorial will show how to create a query that retrieves a count of unique values in a column of a table. To make this query work, we will use […]The post How to Count Distinct Values in a Table In...

View Article

How to Handle Null Values with the COALESCE Function in SQL Server

This tutorial will show how to use the COALESCE function to handle null values at run time. The COALESCE() function is used to specify how we want to treat NULL […]The post How to Handle Null Values...

View Article


How to Calculate the Average of a Numerical Column SQL Server

This tutorial will show how to calculate the average of a numerical column with the AVG function in SQL Server. The AVG function returns the average value of a numeric column […]The post How to...

View Article

How to Round a Numeric Column to a Specified Decimal Count in SQL Server 2008 R2

This tutorial will show how to round a column to a specified decimal count. This is possible with the ROUND function. The ROUND function is used to round a numeric field […]The post How to Round a...

View Article


How to Use the OVER Clause in SQL Server 2008 R2

This tutorial will show how to use the OVER clause in SQL Server 2008 R2. The OVER clause exposes a window of rows to certain kinds of calculations. The window […]The post How to Use the OVER Clause in...

View Article

How to Concatenate Non Numerical Columns in SQL Server 2008 R2

This tutorial will show how to use the string concatenation in SQL Server 2008 R2. The string concatenation uses a plus sign(+) operator to concatenate strings. It allows two strings […]The post How to...

View Article

How to Call the LEN Function on a String in SQL Server 2008 R2

This tutorial will show how to use the LEN function in SQL Server 2008 R2. The LEN function returns the number of characters in an input string, excluding trailing blanks. […]The post How to Call the...

View Article
Browsing all 20 articles
Browse latest View live


Latest Images