TSQL Challenge - Table Truncation - 29 Jul 2011 Commented on: 4 years ago (July 30, 2011) How important is it that the view V1 reports the correct values throughout the (fast clearing) operation?
TSQL Challenge: Packing Date and Time Intervals Commented on: 4 years ago (January 29, 2011) Is anything to be gained from taking advantage of the 60-minute maximum for a session in the test data, Itzik?
T-SQL Challenge with SQL Server 2012’s Sequence Object Commented on: 4 years ago (December 16, 2010) Most efficient way I can think of is to have the sequence INCREMENT BY 2 each time, and insert (NEXT VALUE FOR dbo.Seq1) and (NEXT VALUE FOR dbo.Seq1 + 1) into key1 and key2 (respectively) in T1....
SQL Server 2012 T-SQL at a Glance – Sequences Commented on: 4 years ago (November 23, 2010) I believe I'm right in saying that other than column order, the order of items in the SELECT list doesn't mean anything - so it would be wrong for SQL Server to arbitrarily provide e.g. 1 as the...
Geekiest Sig Challenge Commented on: 5 years ago (February 2, 2010) Now that's just geeky to the max! If you had written a .Net app to pull out the pixel positions I'm not sure whether it would've been more or less geeky, mind. :)
Solutions to Logic Puzzle - Crossing a Desert Commented on: 5 years ago (December 9, 2009) The only trouble is, Itzik, that when you return to the first spot where you deposited the food you find it has been eaten by camels! Thankfully, you capture one of them, ride it for three days...
Solutions to T-SQL Challenge - Efficient Partitioned TOP Commented on: 5 years ago (October 31, 2009) You can cheat by relying on the randomness of the data inserted into the table an put "WHERE col1 > 95" at the end of the inner query - limiting the size of the sort. Not recommended for production...
Virtual Auxiliary Table of Numbers Commented on: 5 years ago (October 30, 2009) I've tried the recursive approach you suggest, oddsock and as per article #94376, having the OPTION within the function doesn't work (syntax error) - it'd be a huge pain to have to remember to...
T-SQL Challenge - Duplicating Form Entries Commented on: 6 years ago (August 25, 2009) ccasimor - yes it is possible to insert into two tables in a single statement in SQL Server 2008.
Optimizing a Suboptimal Query Plan Commented on: 6 years ago (March 26, 2009) Hi Itzik, Further to my earlier reply - here are some timings (T1 w/ 1,000,000 rows, col2 'pseudorandomizedish' - SQL Server w/ 768MB RAM, testdb and tempdb on separate disks). Original query: 29s...

Digital Magazine Archives

Browse back issues of SQL Server Pro, from January 2007 through the last issue published in April 2014. Find the back issues here.

 

From the Blogs
Aug 27, 2015
blog

A Replacement for Maintenance Plan Backups

This blog post is a bit of a ‘repeat’ – since I already covered much of the rationale behind this post in Part 23 of my multi-part series on AlwaysOn Availability Groups and SQL Server Agent Jobs. But, I also figured that this is enough of an important topic to merit its own blog post....More
Aug 19, 2015
blog

Looking forward to Containers

Virtualization has long been a staple when it comes to computing. In essence, virtualization is really just the use of abstraction to make things either easier to manage or more fault-tolerant. Disks, for example, have long been virtualized in the sense that a single, physical, can easily be divided up into multiple logical (or virtual) volumes (or drives) just as easily as a number of discreet physical disks can also be virtualized into a single drive (via RAID) – which can further be partitioned into volumes, LUNs, and so....More
Jul 28, 2015
blog

AlwaysOn Availability Groups and SQL Server Jobs, Part 29: Practical Implementation Tips

My initial goal in writing this series of posts was to outline some of the concerns surrounding Availability Groups (AGs) and SQL Server Agent Jobs – and call out how there is virtually no guidance from Microsoft on this front and then detail some of the pitfalls and options available for tackling this problem domain. I initially expected this series of posts to have between 25 and 30 posts – according to some of the early outlines I created ‘way back when’....More
SQL Server Pro Forums

Get answers to questions, share tips, and engage with the SQL Server community in our Forums.

Sponsored Introduction Continue on to (or wait seconds) ×