SQL Server v.Next (Denali) : Another SSMS bug that should be fixed
Sorry to call this out in a separate post (I talked about a bunch of SSMS Connect items the other day), but Aaron Nelson (blog | twitter) jogged my memory today about an issue that has gone unfixed for years: the custom coloring for Registered Servers is neither consistent nor global.
For one of my servers, I've chosen a red color to show in the status bar. Let's pretend this is a production server, and I want the red to remind me to use caution. I can set this up by right-clicking a Registered Server, choosing Properties, and moving to the Connection Properties tab:
Once I save, a new query window – when launched by right-clicking the Registered Server and choosing New Query – looks like this:
This is a great feature, if only it worked all the time.
For example, if I right-click within the above query window and choose Connection > Change Connection, and switch to a server that doesn't use a custom color (or uses a different color), the status bar stays red. More importantly, if I'm in a query editor for a connection without a custom color, and I switch the connection to my production server, the color does not change to red.
Similarly, if I open a new instance of SSMS and click on New Query (or am prompted because my Startup option includes new query window), the status bar remains the default yellowish color, not red.
These gaps in functionality defeat the purpose of the visual cue, and I am hoping that a fix can be addressed in the Denali timeframe. I wanted to call this one out separately because it can lead to pretty serious errors.
There are two Connect items about this issue; one has been closed as "Won't Fix" and the other (which came earlier!) has yet to see a response from Microsoft. I'm hoping that with enough steam we can change that: please vote and comment!
Connect #533667 : SSMS Connection Colouring Not Implemented Sensibly
Connect #504418 : [SSMS] Make color coding of query windows work all the time
There are workarounds, of course: always use Registered Servers to launch your query windows, use Mladen's free SSMS Tools Pack, be a lot more careful, etc. etc. But personally I feel that such a useful built-in feature should be rectified to function reliably.
When you "Change Connection", or click "Connect" in the Object Explorer, you need to click "Options" and set the custom color there also. There are two different places that it needs to be set, but they ought to be integrated to work together.
And please roll color coding into CMS so I can color code all the servers and have everyone in the DBA team on the same page!
Another bug in this functionality is that when you right-click an existing stored procedure and select modify you don't get color-coding. You do get the color-coding if you do Script -> New Query Editor Window. I'm using the 2008 tools, not 2008 R2, so maybe it has been corrected in R2.
On more reason to install my SSMS Tools Pack 🙂
For those of us that work in multiple environments all day long (dev/test/production) I agree this is a major annoyance that can lead to code being run on the wrong servers.
No problem, my frustration lies entirely at Redmond.
But let me plug an article I wrote about that frustration: http://michaeljswart.com/?p=809
Michael, sorry I missed yours! It didn't show up in the two searches I tried.
And those are very very similar to mine from August 2008. I even uploaded a wmv file describing the issue. Extra votes on this one are welcome too!
SSMS Tools is definitely better. One of the first things I noticed post-install was that the color-coding worked properly. As for the Connect tickets, I wish I could say that I was surprised by the "won't fix" response. I think I saw the same thing for the "Remember me" functionality which also doesn't work consistently. Save user/password and at some random point that password disappears. I can reproduce it over time, but can't figure out why that happens. Submitted to Connect and it's a "won't fix" resolution. 😛
The epitome of a half-finished feature!