DECLARE @startofyear DATETIME, @endofyear DATETIME SET @startofyear = DATEADD(yy, DATEDIFF(yy,0,getdate()), 0) SET @endofyear = DATEADD(yy, DATEDIFF(yy,0,getdate()) + 1, -1); WITH sample AS ( SELECT @startofyear AS [Date] UNION ALL SELECT DATEADD(dd, 1, [Date]) FROM sample s WHERE DATEADD(dd, 1, [Date]) <= @endofyear) SELECT * FROM sample option (maxrecursion 370) –loop not more than 370, change to zero to infinite
Wednesday, July 2, 2014
T-SQL: Get a list of dates
Returns a list of dates from first of year to end of year
Labels:
T-SQL
Subscribe to:
Post Comments (Atom)
Packers And Movers Bangalore Local Household Shifting Service, Get Free Best Price Quotes Local Packers and Movers in Bangalore List , Compare Charges, Save Money And Time @ Packers And Movers in Bangalore
ReplyDeleteGreat Article Cyber Security Projects projects for cse Networking Security Projects JavaScript Training in Chennai JavaScript Training in Chennai The Angular Training covers a wide range of topics including Components, Angular Directives, Angular Services, Pipes, security fundamentals, Routing, and Angular programmability. The new Angular TRaining will lay the foundation you need to specialise in Single Page Application developer. Angular Training
Delete
ReplyDeleteاننا نقدم العديد من الخدمات يمكنك زيارتها :
ارخص شركة نقل عفش بالمدينة المنورة
شركة نقل عفش بالمدينة المنورة
__
شركة تنظيف بالكويت
___-
شركة تنظيف الكويت
___
شركة تنظيف مكيفات بالرياض
افضل شركة صيانة مكيفات بالرياض
شركة صيانة مكيفات بالدمام
Packers and Movers Hyderabad Give Certified and Verified Service Providers, Cheap and Best ###Office Relocation Charges, ***Home Shifting, ???Goods Insurance worth Rs. 10,000, Assurance for Local and Domestic House Shifting. Safe and Reliable Household Shifting Services in Hyderabad with Reasonable Packers and Movers Price Quotation @
ReplyDeletePackers And Movers Hyderabad
Local Packers and Movers Bangalore List, Get Best Price Quotes, Compare Movers and packers Charges, Top, Local Household Shifting Services
ReplyDeletePackers And Movers Bangalore
Packers and Movers Bangalore as a Services providing company can make all the difference to your ###Home Relocation experience. Bangalore based Company which offers versatile solutions, Right team that easily reduce the stress associated with a ✔✔✔Household Shifting, ***Vehicle Transportation. we help things run smoothly and reduce breakages and offer you seamless, Affordable, Reliable Shifting Services, Compare Shifting Charges @ Packers And Movers Bangalore
ReplyDeleteThis comment has been removed by the author.
ReplyDeleteThe Most Reliable Packers And Movers Bangalore And Trusted Partners For All Your Packing,
ReplyDeleteShifting And Relocation Services: Packers and Movers Shifting Services in Bangalore helps you relocate to and from Bangalore,
within city, Interstate, domestic and International destinations. Absolutely stress and Hassle-free Shifting Services in Bangalore.
As part of our services, we also offer a host of other complimentary relocation services designed to meet both individuals specific
moving and relocating needs and companys corporate relocation objectives. We are the best local option for Shifting, domestic Shifting, Household packing, Commercial movement, Vehicle transportation in Bangalore and all that you wish to relocate. @ Packers And Movers Bangalore
Get Shifting/Relocation Quotation from ###Packers and Movers Delhi. Packers and Movers Delhi 100% Affordable and Reliable ***Household Shifting Services. Compare Transportation Charges and Save Time, Verified and Trusted Packers and Movers in Delhi, Cheap and Safe Local, Domestic House Shifting @
ReplyDeletePackers And Movers Delhi
Spolu offers OnePlus, Mi, Vivo, Lenovo & iPhone all types od mobile mobiles repair service at your doorstep. All our phone repairs come with 6 months warranty, same day service. We'll send you a text with a link to download the app.
ReplyDeleteYou can download the mobile app here-
Doorstep Mobile Repair Service in Noida
Orel State University which is also known as Government State Educational Institution of Higher Education is identified as a prime higher education Institution in the metropolis of Orel. Orel State University was founded in 1931 as an industrial-Pedagogical Institute. In 1932 Orel Pedagogical University became Orel State University. Orel State University is unique in many aspects.
ReplyDeleteTo get Admission and more information-
Orel State Medical University
Packers and Movers Chennai Give Safe and Reliable ***Household Shifting Services in Chennai with Reasonable ###Packers and Movers Price Quotation. We Provide Household Shifting, Office Relocation, ✔ ✔ ✔ Local and Domestic Transportation Services, Affordable and Reliable Shifting Service Charges @ Packers And Movers Chennai
ReplyDeleteYour site is truly cool and this is an extraordinary moving article..@
ReplyDeletePackers and Movers Ahmedabad
I am really enjoying reading your well written articles. I think you spend numerous effort and time updating your blog. @ Packers And Movers Bangalore
ReplyDeleteWe performed at Wild Casino from completely different cellular gadgets and tablets, and the gameplay was smooth and pleasant each time. Their website is perfectly optimized for the smaller screens of smartphones. If your first deposit is made using fiat cash, you will be be} rewarded with a 250% deposit up to as} $1,000. However, it ought to be famous that the wagering requirement is 45x for the crypto welcome bonus, while for the fiat supply, it is 35x. The largest advantage of this online on line casino is that it processes payouts really 온라인카지노 quick.
ReplyDelete