Technical Article

Sproc to get First Day of the Month,First Weekday ETC

First Day of the Month, First Weekday, Total Days in this Month, Days In First WeeK, Days In Last Week,Total Weekend Days sample output: Given Date:Jul 16 2005 12:00AM First Day of the Month:7/1/2005 First Weekday (sun=1,sat=7):6 Total Days in this Month:31 Days In First Week:2 Days In Last Week:1 Total Weekend Days:10

You rated this post out of 5. Change rating

2005-07-15 (first published: )

209 reads

Blogs

Check your regions people

By

Today I was having a nice discussion with some colleagues about Fabric and pricing/licensing...

Using Git Prune–#SQLNewBlogger

By

As I’ve been working with SQL Saturday and managing changes to events, I’ve accumulated...

Microsoft Purview new data governance features

By

Starting last week is a rollout of the public preview of a new and...

Read the latest Blogs

Forums

Degraded Performance in 2017 vs 2008 R2 with inserts

By MichaelT

We're finally upgrading from SQL Server 2008 R2 Enterprise to SQL Server 2017 Standard...

Do I need a recursive query for this? bill of materials (sort of)

By pietlinden

I am working on a data warehouse project for a bakery. For the most...

Do I need a recursive query for this? bill of materials (sort of)

By pietlinden

I am working on a data warehouse project for a bakery. For the most...

Visit the forum

Question of the Day

Restoring the Resource Database

How can I restore a version of the Resource Database in SQL Server 2022?

See possible answers