SQL Server Date Between

SQL Server Date Between

In this article, I’ll walk you through everything you need to know about working with date ranges in SQL Server, with a specific focus on the BETWEEN operator. SQL Server Date Between Before diving into specific techniques, it’s essential to understand how SQL Server handles dates. SQL Server stores dates in a standardized internal format, … Read more

SQL Server Date In Where Clause

SQL Server Date In Where Clause

In this comprehensive article, I’ll cover everything you need to know about using dates in SQL Server WHERE clauses, from basic syntax to advanced techniques. SQL Server Date In Where Clause The first challenge when working with dates in SQL Server is understanding the available data types. Common Date Data Types in SQL Server SQL … Read more

‘to_date’ is not a recognized built-in function name.

'to_date' is not a recognized built-in function name.

Recently, I was trying to convert a date to a specific format in SQL Server using the to_date function. But after executing the SQL query, I got this error. ‘to_date’ is not a recognized built-in function name. I was trying to execute the following query. After executing the above query, I got this error as … Read more

SQL Server Get Today’s Date

SQL Server Get Today's Date

In this comprehensive article, I’ll explain the various approaches to getting today’s date in SQL Server and help you choose the correct function for your specific requirements. SQL Server Get Today’s Date Before diving into the specifics, it’s essential to understand that SQL Server provides multiple built-in functions for retrieving the current date and time. … Read more

SQL Server Extract Year From Date

SQL Server Extract Year From Date

In this comprehensive article, I’ll explain multiple approaches to extracting the year from dates in SQL Server, with examples and best practices. By the end of this tutorial, you’ll have a clear picture of this. SQL Server Extract Year From Date Now, let’s explore the different methods for extracting the year from a date in … Read more

‘EXTRACT’ is not a recognized built-in function name.

'EXTRACT' is not a recognized built-in function name.

Recently, I was working on a requirement to extract the year from a date in SQL Server. After executing the SQL query, I got this error. ‘EXTRACT’ is not a recognized built-in function name. I was executing the following query. After executing the above query, I got this error as shown in the screenshot below. … Read more

SQL Server Insert Date

SQL Server Insert Date

In this comprehensive article, I’ll cover everything you need to know about inserting dates into SQL Server, from the basics to advanced techniques that I have learned working as a senior SQL resource for a long time. SQL Server Insert Date Before going deep into insertion approaches, it’s essential to understand the different date and … Read more

SQL Server Get Month From Date

SQL Server Get Month From Date

In this comprehensive article, I’ll provide real-time examples of multiple approaches to extracting the month from a date in SQL Server. This is one of the requirements that I recently got for one of my applications. SQL Server Get Month From Date Let us discuss all the possible approaches individually. Approach 1: Using the MONTH() … Read more