Click here to monitor SSC
SQLServerCentral is supported by Redgate
Log in  ::  Register  ::  Not logged in

Get your favorite SSC scripts directly in SSMS with the free SQL Scripts addin. Search for scripts directly from SSMS, and instantly access any saved scripts in your SSC briefcase from the favorites tab.
Download now (direct download link)

IsDateAHoliday UDF **NEW**

By Joe Colletti,

This is a replacement script for the first IsDateAHoliday. The first one was too slow and inefficient. This one is much better. Enjoy.
IsDateAHoliday is a User Defined Function that accepts a date and returns a 1 if date is a national holiday and returns a 0 otherwise.
The holidays are:
New years Day, MLK Day, Presidents Day, Memorial Day, Independance Day, Labor Day, Columbus Day, Veterans Day, Christmas Eve and Christmas Day

Total article views: 400 | Views in the last 30 days: 5