Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Excluding weekend and holidays in query 1

Status
Not open for further replies.

scon165

Technical User
Dec 27, 2001
7
US
I have a query which right now is subtracting two dates and then returning only those records which are <= 5. Here is a sample from the where clause:
(av.status_date - av.requested_date) <=5. We have to report Turn around times and need to exclude weekends and holidays. Can anyone tell me how to do it in a query.
 
Holidays aren't built into Crystal.

Here's the whitepaper:


Although I suggest that you create a Period table which identifies all days with various attributes (Holiday, biz day, weekend, quarter, fiscal quarter, etc.), and then just join to it.

It's standard fare in a Data Warehouse, and should prove an invaluable resource for other types of reporting.

-k
 
How does one create a period table. Need to create a very complicated fiscal period that is made up of a pattern of weeks, 4 weeks/4weeks/5weeks....
 
That would depend on your database, I responded to your other post.

Consider posting meaningful technical information when requesting it.

-k
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top