Luis Cazares

Calculating Working Hours

Calculating working hours can be painful due to all the variances that they imply. This function will calculate working hours between 2 dates which might include time. There's an option to use a holidays table that will vary in each environment.

4.67 (3)

2015-10-22 (first published: )

3,614 reads

Blogs

Sorting in Stored Procedures – Food for Thought

By

We know that sorting can be one of the most expensive things in an...

Trace Query in Extended Events

By

The ability to quickly and easily trace a query is important to database professionals....

Using Erik Darling’s sp_pressure_detector to resolve CPU issues

By

Last Friday I spent my lunch break going through some links I had marked...

Read the latest Blogs

Forums

Replication causing log bloating

By tarr94

Hello, We've had a replication process in place for several years.  It seems like...

How to import Excel with XML

By itmasterw 60042

Hi, I have an Excel sheet that I have to import into SQL Server....

Recursive CTE - Batches

By koti.raavi

Hi Folks I'm trying to group rows into batch and adding batch to query...

Visit the forum

Ask SSC

SQL Server Q&A from the SQLServerCentral community

Get answers