Technical Article

Get FirstDate and LastDate of Every month from two Dates

Get FirstDate and LastDate of Every month from two Dates.

Like IF we have @date1='05/02/2015' and @date2= '11/25/2015' then we will get list of first date and last date from month 5 to 11.

SELECT ID,FirstDate,LastDate,Month,Year FROM [GetFLDatelist](@date1,@date2)

2.4 (5)

You rated this post out of 5. Change rating

2015-11-09 (first published: )

1,250 reads

Blogs

Speaking at SQL Saturday South Florida 2024

By

I’m heading to SQL Saturday South Florida 2024 next week. This is my second...

The Next Phase & A Fresh Start

By

As of June 1, I am no longer an employee at 3Cloud. I am...

How do you restore a SQL Server 2000 database in the year 2024?

By

A discussion on LinkedIn led to this hypothetical “real world” question: Problem statement: I...

Read the latest Blogs

Forums

The Secondary Database Name in an AG

By Steve Jones - SSC Editor

Comments posted to this topic are about the item The Secondary Database Name in...

Cloud Transformation

By Steve Jones - SSC Editor

Comments posted to this topic are about the item Cloud Transformation

How I Used PostgreSQL RLS To Avoid Code Changes During a Migration

By shwets.ven@gmail.com

Comments posted to this topic are about the item How I Used PostgreSQL RLS...

Visit the forum

Question of the Day

The Secondary Database Name in an AG

I am setting up a SQL Server 2022 Availability Group and I am ready to restore the database on the secondary. The primary database is named Finance. However, we also use this instance for QA and already have a database named Finance. How do I configure the AG to use a different database as the secondary?

See possible answers