May 11, 2009 at 4:10 am
function or procedure for dynamic generation of weeks for given month period. lets take if i give range march to may i have to get the number of weeks like mar1week(01/03-07/09)....May4wee(23/05-30/05) like that
May 11, 2009 at 4:38 am
What have you tried so far?
Did you look into DATEADD/DATEPART functions in BOL?
May 11, 2009 at 5:00 am
May 11, 2009 at 2:10 pm
Hi,
you should consider using a calendar table.
A start point would be the code posted by GSquared in http://www.sqlservercentral.com/Forums/FindPost513748.aspx
May 11, 2009 at 2:38 pm
I agree with the calendar table idea, but I still think you should answer the questions I posted on the other thread you started with the same question, http://www.sqlservercentral.com/Forums/Topic714216-9-1.aspx. Just post the answers here as everyone will be watching this thread now.
Jack Corbett
Consultant - Straight Path Solutions
Check out these links on how to get faster and more accurate answers:
Forum Etiquette: How to post data/code on a forum to get the best help
Need an Answer? Actually, No ... You Need a Question
Viewing 5 posts - 1 through 4 (of 4 total)
You must be logged in to reply to this topic. Login to reply