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,247 reads

Blogs

Common Mistakes in SQL Server – Part 2

By

The  Identity property creates an incremental value for the specified column automatically, which is...

Enable PowerShell Remoting

By

Enable PowerShell Remoting I use PowerShell quite a lot...

Get Configuration Change History From the SQL Server Error Logs

By

Get Configuration Change History From the SQL Server Error Logs There...

Read the latest Blogs

Forums

Restore With Standby; A Review and A Lesson Learned

By Andy Warren

Comments posted to this topic are about the item Restore With Standby; A Review...

Are You Worried About AI?

By Steve Jones - SSC Editor

Comments posted to this topic are about the item Are You Worried About AI?

The Upgraded Procedure part 2

By Steve Jones - SSC Editor

Comments posted to this topic are about the item The Upgraded Procedure part 2

Visit the forum

Ask SSC Logo Ask SSC

SQL Server Q&A from the SQLServerCentral community

Get answers