SQL DATEPART Function Use and Examples
Learn how to use the SQL Server DATENAME function to return an integer value for a specific part of a date such as day, hour, month, etc.
Learn how to use the SQL Server DATENAME function to return an integer value for a specific part of a date such as day, hour, month, etc.
In this section we will at different examples of how to use the SQL Server DATEDIFF function to find difference between two dates.
Learn how to use the SQL Server DATEFROMPARTS function to build a valid date with separate year, month and day values.
Learn how to use the SQL Server DATENAME function to return a specific part of a date such as day, hour, month, etc.
In this section we will at different examples of how to use the SQL Server DATEADD function to add days or time to an existing date.
In this article we look at how to use the SQL Server YEAR function to return the integer value for the date provided.
Learn about the SQL SYSDATETIME function to get the current date and time with a much better precision of the current time.
Learn about the SQL CURRENT_TIMESTAMP function and why this should be used instead of the SQL Server GETDATE() function.
In this article we look at how to use the SQL Server DAY function to return the day integer value for a provided date.
Learn about the SQL Server GETDATE() function and how this can be used to get the current date and time.
Learn about the SQL function GETUTCDATE to return the current date and time in Coordinated Universal Time or UTC.
Learn about the SQL Server function ISDATE to determine whether the provided value is a valid or invalid date.
In this article we look at how to use the SQL Server MONTH function to return the integer value for the date provided.
Learn about the T-SQL functions GREATEST and LEAST to easily find the greatest or least value in a set of values when working with SQL Server.
Learn about the different T-SQL aggregate functions in SQL Server such as count, sum, min, max, avg and more along with examples.
In this article we look at different ways to format currency output in SQL Server and most notably the different options the FORMAT function provides.

In this article we cover different ways to format numbers in SQL Server using various functions like CAST, CONVERT, ROUND, CEILING, FLOOR and FORMAT.
In this article we look at various ways to use the SQL COUNT function in SQL Server to get row counts.
In this article we look at how to concatenate SQL Server data using various methods using concatenation operator, functions CONCAT and CONCAT_WS.
Learn how to convert SQL Server data to different data types such as string, date, integer and numeric using the CAST and CONVERT functions.
This article demonstrates how to use a calendar table to solve scheduling problems using environment-wide server patch management as an example.
In this article we look at how to use the CAST function to change the data type for some data as well as compare CAST, CONVERT and PARSE functions.
In this article we will explore several SQL Server Date Functions and show many examples of the date functions usage.
Learn how to easily query and get different SQL Server server level properties by using the TSQL function SERVERPROPERTY().