I need to generate the financial week but in my case the starting month of the financial week ill get change for that am using the parameter to get the starting month.Please help me to get that.
This is static query in which i consider April as the starting month. like i need to generate.
declare @date datetime='2013-4-01'
select CASE WHEN DATEPART(WW,@date)<=13 THEN 40+DATEPART(WW,@date) ELSE DATEPART(WW,@date)-13 END