SQL Clone
SQLServerCentral is supported by Redgate
Log in  ::  Register  ::  Not logged in


My name is Kenneth Fisher and I am Senior DBA for a large (multi-national) insurance company. I have been working with databases for over 20 years starting with Clarion and Foxpro. I’ve been working with SQL Server for 12 years but have only really started “studying” the subject for the last 3. I don’t have any real "specialities" but I enjoy trouble shooting and teaching. Thus far I’ve earned by MCITP Database Administrator 2008, MCTS Database Administrator 2005, and MCTS Database Developer 2008. I’m currently studying for my MCITP Database Developer 2008 and should start in on the 2012 exams next year. My blog is at www.sqlstudies.com.

Archives: October 2013

Adding a column to a table with a default (NULL vs NOT NULL)

There are lots of ways to learn new things, or be reminded of old things. One of my favorites is the QotD on sql server central. Recently there was an interesting question on defaults. It pointed out that there is a difference between adding a column with a… Read more

3 comments, 4,630 reads

Posted in SQLStudies on 30 October 2013

Change in SQL 2012 SSMS grid output behavior

It’s one of those things that always aggravated me but not really enough to complain about. When you run a query to grid in SSMS then copy and paste the value to a query window it stripped the carriage return/line feed.

-- Setup code
CREATE TABLE GridTest (String varchar(50))

Read more

0 comments, 687 reads

Posted in SQLStudies on 28 October 2013

Unexpected truncation in FETCH

Yes I’m talking about FETCH as in a cursor, yes everyone hates cursors. But you know cursors are like anything else. It’s good to know everything you can and they do have their place. In fact there are two very specific places that I see cursors.

First: You need to… Read more

0 comments, 694 reads

Posted in SQLStudies on 23 October 2013

A look at comments

Everyone knows that we should include comments in our code right? On the other hand the vast majority of us don’t use them as much as we should, myself included. Believe it or not I actually got a job based on the comments I had put into the tech test.… Read more

10 comments, 1,721 reads

Posted in SQLStudies on 21 October 2013

Query to compare indexes between two tables

We have a set of databases at my office that use the load and swap method of loading data with minimal effect on the users. In case you haven’t heard of this before if you have a table that is modified during a batch process only (no user writes at… Read more

0 comments, 1,191 reads

Posted in SQLStudies on 16 October 2013

Why you should know how to script as well as use the GUI

Personally I’ve always enjoyed learning the T-SQL for any given task. The GUI is usually pretty easy to figure out but I’ve found that for standard tasks it can be quite a bit faster to just use a script. In fact I posted a while back on using the script… Read more

0 comments, 995 reads

Posted in SQLStudies on 14 October 2013

I’ve refreshed a test database from prod but now the users can’t access it.

This happens to me all the time. I get a request from a developer to overwrite the test copy of a database with the production copy. Typically this is so they can use real data for testing although there are other reasons.

So first I go around to everyone who… Read more

4 comments, 2,657 reads

Posted in SQLStudies on 9 October 2013

T-SQL Tuesday #47: Your Best SQL Server SWAG

It’s time for T-SQL Tuesday again and this time Kendal Van Dyke is asking for Your Best SQL Server SWAG. This is my first T-SQL Tuesday, not from lack of interest or knowledge, but to be honest mostly because I can’t seem to remember when the second Tuesday of the… Read more

0 comments, 738 reads

Posted in SQLStudies on 8 October 2013

Use TOP instead of SET ROWCOUNT

Both TOP and SET ROWCOUNT are both valid methods of limiting the result sets from a query. They are however very different commands. The TOP clause of a command limits that single command, while the SET ROWCOUNT command limits all eligible queries within the connection until another SET ROWCOUNT is… Read more

10 comments, 3,939 reads

Posted in SQLStudies on 7 October 2013

Filtering Object Explorer

I absolutely love learning new tricks that can be done in SSMS. Everything from opening initial connections to both the object explorer and a query window to changing the font that the query windows use. Recently I learned a new one while watching a SQL Skills Insider video. I’ve… Read more

3 comments, 877 reads

Posted in SQLStudies on 2 October 2013