SQL Server (RSS)

Attending the PASS Summit

Steve Jones makes some good points in his blog post Training. I find it difficult to believe the short-sightedness of some organizations when it comes to training events like the PASS Summit.

This year's Summit - like all previous years to date - had enough top notch presentations and labs to make it worth the cost of admission, travel and expenses, and the cost of allowing a database professional to leave work for three days combined. More than enough.

Like Steve, I don't get it.

Also like Steve, I bet we'll see these DBAs at the 2008 PASS Summit in Seattle - and working for another company.

I wonder if those responsible for denying database professionals opportunities for training factor in the cost of hiring and training a new DBA every six to eighteen months?

:{> Andy

Technorati Tags: EMPs Database Professionals PASS Training Changing Jobs

Getting Ready For The PASS Summit!

The PASS Summit is less than two weeks away!

I'm getting ready for my presentations. I need a couple laptops to host virtual servers for the demos, so I bought some new gear to take with me.

Check out my Network-In-A-Bag!

Network in a bag!

It's a power strip, a couple CAT6 cables, power supply, and a NetGear 1G 5-port switch - all in a 1 gallon Ziploc bag.

:{> Andy

Technorati Tags: PASS Summit 2007 Networking

Iteration = Maturity

Introduction 

I was recently reminded that iteration matures software.

The History of Andy, Part 1 

Like many DBAs, I was a software developer in another life. I built web applications - working my way up from HTML through DHTML and finally to ASP - and could regale (and bore) you young whipper-snappers with war-stories of how things were "back in my day". [/DanaCarvey]

But I won't.

The Times They Are a-Changin'

I'll share instead something I've witnessed many times since starting with software in 1975 - and something you probably already know: stuff changes.

And thank goodness stuff changes!

I recently ordered 1G of RAM from an online retailer. It should arrive before my next son (but that's not a given as Riley refuses to provide a tracking number - the doctors will induce Christy into labor Friday if he hasn't been born by then - but I digress...). I remember my neighbor John, who introduced me to computers, purchased a 256-byte RAM chip in the mid-1970s for about what I paid for the 1G. That's 256 bytes of RAM - not a typo. As I recall it was either a 14- or 16-pin IC.

Things have changed since then. Improvements in technology, brought about by building and improving upon existing knowledge, have brought us to a day when I can purchase 1,073,741,824 bytes for roughly the previous price of 256. I don't know how you feel about that. I think it's a good thing.

The idea of "building and improving upon existing knowledge" defines iterative development. Although the idea is relatively new to the software development field, it serves as the basis for engineering disciplines. Engineers iterate - build and improve upon existing knowledge - and we get more powerful hardware for the same amount of money. What's not to like?

Iteration - it's not just a good idea... 

Iterative software development builds and improves upon existing knowledge within a specific domain. Most domains are defined by an application (wholly or in part), enterprise knowledge (again, wholly or in part), or - most likely - some combination of the two. For example, let's say you work for a large corporation as a software developer. Your domain could be the corporate website. In which case you possess knowledge about the business of the corporation and web development. You mix these together to do your job. In this case, you will probably pick up marketing savvy and current trends along with the latest AJAX techniques.

As you make successive passes (iterations) through the website design interacting with marketing, your domain knowledge is built and improves. As your domain knowledge increases, the website will become more valuable to the corporation - as will you.

Iteration adds value.

Got Iteration?

The same can be said for database development.

Perhaps you've experienced this in your own database development efforts: you receive a request for a database design to meet some desired functionality. Or you're handed a design and asked to optimize it. Or maybe even you had an idea to capture data - performance metrics or something similar - and you're designing a database solution to accomplish this.

You get into the development a few hours or a few days and realize a little tweak here or there would improve performance, or readibility, or better adapt the design to your intentions. So you make the tweak and continue.

This improvement leads you to re-examine other portions of the design and you make more tweaks. Maybe your last change broke things. Maybe you see an opportunity to add a parameter to a stored procedure and combine the business logic of three stored procedures into one.

A "Growing" Solution 

Pretty soon, you have iterated enough to feel comfortable promoting, integrating, or even releasing the results - letting the effort move to the next step.

Depending on the nature of your efforts, it may not end there. If your database development is the back end of a larger application - say, the corporate website, for example - there will likely be requests for changes over time as the site grows (scales) in complexity and size.

When the requests come in you are not likely to start over. You will most likely build and improve upon your existing knowledge. You will most likely iterate.

Scaling forces iteration.

Voilà

This is how solutions mature - be they applications, databases, or both - regardless of who writes them or how many are involved in the development effort. It doesn't matter if the development team is one lady in a cubicle in the European Union or a development team of thousands at Microsoft.

Iteration matures software.

:{> Andy

Meltdown!

A couple days ago the Vista Ultimate instance on my laptop when all Klingon on me: it was "a good day to die."

I'll never know why for sure. Indications point to COM+ and VMM giving up the ghost. They were good systems, may they rest in peace.

I tried to revive the old OS. It would run in Safe Mode and even Safe Mode with Networking, but that's just not the same as having all the functionality I know and love.

I've spent the last couple days (and nights) rebuilding a second instance of Vista Ultimate on the same machine. I'm about half done at this point. Today is SQL Server instances and Visual Studio Team System day.

It's not just the installs, there's the service packs and updates after the installations. Lots of installing.

But it's also an opportunity to rebuild the machine with a different configuration.

Back to installing...

:{> Andy

Technorati Tags: Vista Re-install

SQL Server 2005 Books Online Update

There's an available.

Major changes include information regarding installation of SQL Server Express SP2 on embedded systems and updates on the WITH ENCRYPTION topic.

:{> Andy

Technorati Tags: SQL Server 2005 Books Online

RowCount and Stored Procedures

Recently I thought the SQL Server RowCount functions were lying to me - telling me there was only one row being returned by stored procedures that performed Select statements only - Select statements that I knew returned more than a single row.

I discovered the culprit after some digging: the Return statement at the end of the procedure was, in fact, returning 0 - which is technically one row.

:{> Andy

Technorati Tags:

SQL Server 2008 CTP Available!

The June CTP of SQL Server 2008 (the database server formerly known as Katmai) at !

Registration is required. You must also complete a three-question survey.

:{> Andy

Technorati Tags: SQL Server 2008 Katmai CTP

Notes On Project Success - Part 2, to Stake-Holders

Yesterday, I addressed Technologists regarding Project Success; today I address Stake-holders.

I have participated in projects that have succeeded and in projects that have failed. One thing I noticed about the failed projects: expectations were poorly - or not - managed.

What are examples of project expectations?

  • Functionality - when completed, the application / upgrade / database / server will allow me to perform xyz.
  • Time - how much time one expects to develop the functionality. Can also include a schedule for deliverables and / or milestones.
  • Expense - how much one expects to pay for the functionality.

As a stake-holder you know what you want. And you can probably communicate your expectations - using the three areas above as a guide - effectively. Issues arise when, for whatever reasons, there is a disconnect between your expectations and the those of the IT team tasked with performing the work.

I've witnessed several unsuccessful executive responses to the disconnect scenario:

  • "Ostritch" - ignoring the disconnect in hopes it will disappear with time.
  • "Gambler" - belief that there's a big score (project or technical break-through) just-around-the-corner that will save the day.
  • "Taskmaster" - belief that threatening people is the way to motivate them to work around challenges.
  • "More-Resources" - a firm belief that more resources can solve any problem known to humanity. (I often imagine these folks live in subdivisions and get their neighbors to help mow their lawns. In my mind I see forty push-mowers aligned wheel-to-wheel along one edge of a lawn. On signal, they all puch across the lawn, mowing it from end to end in a single pass...)

I worked for a company that decided to employ Performance-Based Management techniques to a successful team. They actually applied the concept company-wide, regardless of whether the teams were successful or not. In this particular flavor of PBO, 20% of employees were considered outstanding, 60% were satisfactory, and 20% were acceptable losses that the company would be better without. These numbers were set in stone and never changed.

My questions were:

  • Who failed? Did HR fail 80% of the time by hiring mediocre to poor employees? or did our management disillusion and de-motivate these people into their non-excellent state?
  • Are we, in effect, planning to never get better?

Statistical control works on processes, not people - at least not well on people.


So what is the solution?

Communication.

It's that simple. Executives have to either be approachable by the IT team or someone representing them, or you must appoint someone to be approachable in your stead. Leadership dynamics (or just plain scheduling issues) may require you to appoint someone. If so, try to find someone who speaks both business and technology.

Realize that sometimes you do not know what you do not know. I run a couple small corporations and have an appreciation for the amount of work involved in merely administering such an entity. I also know technology changes every day. It's difficult for anyone to keep up - especially if you're minding stock-holders, regulators, and the lot. We may have moved beyond the technology you understand. If we haven't, we will soon.

Either hire people you trust or trust the people you hire. If someone violates the trust, respond accordingly. But do everything within your power to exude trust-worthiness as well as trusting-ness.

For truly innovative people to be free to succeed, they must first be free to fail.

The best tools were once toys. IT professionals are notorious tinkerers. You will be astonished at the return on investment for a weekly-scheduled hour of "play time" for developers.

:{> Andy

Technorati Tags: Software projects Success Failure Technologists

Notes On Project Success - Part 1, to Technologists

There was a very interesting article posted not long ago at SQL Server Central by Janet Wong entitled My Projects Have Never Failed.

In the article, the author explains projects that experienced varying degrees of success for various reasons - but in all cases a disconnect existed between the end-user or customer expectations and the delivered product.

Personally, I consider these projects failures.

Here's why: The stake-holder or executive has this expectation. It may be very unrealistic, but they hold it nonetheless. They may be very educated people or not. They may understand technology or not. None of this impacts the fact that they hold expectations.

Q: Who's in charge of communicating realistic expectations?

A: Technology people.

Or at least a member of the technology team.

A good technology team has several moving parts and people fulfilling different roles.
Note: If you're a one-person-show, this post is not about you.

At least one person on the team needs to be customer-facing. That person needs to be an expert in communicating with business people who hold unrealistic expectations. Make no mistake: this is a talent and an art.

Good communicators are rare in life, rarer in business, and practically extinct in the technology sector. Most good communicators abandoned IT departments decades ago and moved into sales where they could enjoy salaries orders of magnitude beyond what IT departments will pay them. But I digress...

I don't blame my customers when their expectations go unmet - I blame myself. Had I communicated something better - or even differently - the outcome would likely have been better for everyone.


So here are some tips for communicating with project stake-holders / executives:

  • You may understand what you mean when you say "Third-Normal Form Relational Database" at a meeting with executives, but few of them will. It's not their job to understand - that's why they're paying you. Step up. If you cannot translate your conversation into executive-speak, let someone else do the talking. If your point is to embarrass the executives, you'll probably not try that at your next job.
  • Identify someone on your team (or add someone to your team) to serve as a point-of-contact to the executives. If your team has a project manager, they may be the best person to do this. I've also seen horrible project managers who exacerbate the problem with their own inability to communicate (or worse yet, take the side of the stake-holders and hang the development team out to dry).
  • Keep it short.
  • Keep it as simple as possible. Stake-holders and executives do not need to know the history of iterations you went through to arrive at your conclusion. Take it as a sign of confidence in your abilities that they accept your judgment on the matter.
  • Stake-holders and executives have different priorities from you and I technology people - remember that.
  • If you deliver quality late, no one remembers. If you deliver junk on time and under budget, no one forgets.
  • The old consulting axiom ever applies: Under-promise, over-deliver.

This is business. This isn't academia; you do not get to interpret your own results.

It's not a success unless they believe it to be a success.


Me, I've had projects fail. Some of them have been spectacular in the scope of their failure. To date, I've stepped up, admitted the failed status of the project along with my errors, and promptly moved to correct the issues. I've found excuses to be a waste of my and my customer's time.

Having a project fail is bad enough; failing to manage the failure takes it to the next level.

Remember, if you fix it, it will be ok.


Tomorrow, I address Stake-holders.

:{> Andy

Technorati Tags: Software projects Success Failure Technologists

Managing The Thing You Cannot Touch

Yesterday I wrote about The Thing You Cannot Touch. Today I'm going to tell you some ways to manage the situation.

First, try to determine why You Cannot Touch The Thing. This is invaluable information in charting the waters ahead - especially if you're consulting.

Second, accept the fact that there's better than a 90% chance that you will not, in fact, be allowed to Touch The Thing. In my experience, three things must be true for you to overcome the business friction imposed by The Thing:

  • You have to try everything else first.
  • Everything else must fail to sufficiently address the issue.
  • The source of the issue must be mission-critical.

Regardless, your best knee-jerk reaction is acceptance. This is tough for a professional. In your heart of hearts you know what it takes to solve the real issue. And yet, you've been told You Cannot Touch It.

The good news? There's also a better than 90% chance you can find a way to solve the issue - or at least alleviate the client's pain - without Touching The Thing.

Modern enterprise applications are comprised of lots of moving parts. The Thing is probably not the sole source of pain. Addressing other bottlenecks may do the trick - at least for now.

And, if you're the person they called last time they had an issue and you solved it (and weren't "difficult" to work with), you'll likely get the call next time.

How cool is that?

:{> Andy

Technorati Tags: Consulting Software Development Satisfying The Customer Leveraging New Business

The Thing You Cannot Touch

I have this theory about consulting. I call it The Thing You Cannot Touch. Since a few friends have found it amusing I thought I'd share. It goes like this:

A potential client contacts your firm. A conference call is arranged to discuss the issue. During the call, the issue is defined. Resolution theories and attempts to date are shared, along with their results. The current status is explained - along with

The Thing You Cannot Touch.

Sometimes an attempt at justification accompanies the announcement: "We know it can't possibly be _______ so we're not going to waste any time looking at it."

Other times, it's just put out there for what it is: "You can't touch _______."

My experience has shown the heart of the issue almost always lies with The Thing You Cannot Touch. It needs to be fixed but someone, somewhere, for some reason does not believe it to be so - and so it Cannot Be Touched.

Sometimes it's political - It's someone's "baby". They built this application just ten short years ago - worked nights and weekends and toiled and sweated and bled to make it work - and rode it all the way to CIO, after all. Who are you, lowly consultant, to tell them VB 6 code should be re-written in this new fad known as .Net? Doesn't Vista support VB 6 until the mid-20-teens?

Sometimes the decision-maker doesn't understand the differences in the technologies.

Sometimes it's a purely market-driven business decision - and the decision-maker is right and justified in choosing to keep hands off The Thing. It's not all about technology folks... it's sometimes about what I like to describe as the (little "s") software (big "B") Business.

If you find yourself on a consulting conference call and The Thing You Cannot Touch comes up, pay attention. Tomorrow I tell you how to Manage The Thing You Cannot Touch.

:{> Andy

Technorati Tags: Consulting Software Development Thing You Cannot Touch Old Code Outdated Code VB 6

Benefits of 64-bit SQL Server

There's an interesting post out at the SQL Programmability & API Development Team Blog about 64-bit performance enhancements entitled Will 64-bit increase the performance of my SQL Server application?

Interesting stuff - a recommended read.

:{> Andy

Technorati Tags: SQL Server 2005 64-bit performance improvement

SSIS Design Pattern - Incremental Loads Post Now Live at ABI

The latest in my SSIS Design Patterns series - SSIS Design Pattern - Incremental Loads - is now live at Applied Business Intelligence!

:{> Andy

Technorati Tags: SSIS Design Patterns Incremental Load Business Intelligence ETL BI

Tim Tatum's T-SQL Presentation

Tim Tatum did a great job presenting to the Richmond SQL Server Users Group last night! Last night's meeting also set a new attendance record - it was a great night.

Tim thought his topic wouldn't be well-received since most of our presentations focus on SQL Server 2005. Truth be told, there's still quite a market out there for SQL Server 2000. The platform is stable and still meets the database needs of most organizations.

SQL Server 2005 performs better, is more scalable, and has some very interesting and useful features. Not all organizations have a need for SQL Server 2005, and some will not upgrade until .

:{> Andy

Technorati Tags: sql server Tim Tatum Richmond SQL Server Users Group T-SQL

posted Friday, April 13, 2007 10:46 PM by andy with 0 Comments

SQL Provisioning Tool (SQL Server 2005 SP2)

At the end of the SQL Server 2005 SP2 installation you may be prompted to launch the SQL Provisioning Tool. This utility makes members of the local administrators group SQL Server sysadmins - which is cool, especially if your instance security is Windows Authentication only.

If anything "bad" happens during the provisioning process, the utility simply shuts down.

By "bad" I mean things like the tool attempting to access a service you shut down. Note: you may have shut down this service because you were prompted the file was locked during an earlier step in the Service Pack installation.

When you search for the Provisioning Tool in the Start Folders you will note it isn't there.

You can find it with diligent searching (or by reading this blog): It defaults to [Installation Drive]\Microsoft SQL Server\90\Shared\SqlProv.exe. On my machine I installed SQL Server on the C:\ drive so my path to SQLProv is "C:\Program Files\Microsoft SQL Server\90\Shared\SqlProv.exe".

Re-executing the tool doesn't seem to cause any negative impact, but I haven't conducted rigorous testing.

:{> Andy

It's MVP Day

So far as I know, s are annouced the first day of each quarter.

Congratulations to Frank La Vigne who was re-awarded Tablet PC MVP for another year!

Update! Darrell Norton was renewed as an ASP.Net MVP!

Congrats also to David Silverlight, the brains behind Community Credit, XML PitStop, NonProfitWays, Code Camp Evals, and many other cool websites - at least one of which he's asked me not to talk about yet! David was also re-awarded as an XML MVP.

I was nominated for Q3 / 2006 but not awarded. I was disappointed but understood: the process looks at your community involvement over the past year, and I sort of "came out of nowhere" a few months earlier.

I was fortunate enough to be nominated again earlier this year. And today I received the news I was awarded SQL Server MVP! The email arrived around 4:30 AM EDT. I was up until 3:45 AM EDT polishing off my Testing The Database chapter for the upcoming Wrox book: - so I almost knew about it real-time!

It's a huge honor and I am humbled and overwhelmed all at the same time.

:{> Andy

Technorati Tags: About Andy MVP SQL Server

When to Test

All software is tested. Some of it is tested before it's deployed, some immediately thereafter.

;)

It's always good to test before deployment. It's even better to test deployment itself.

I'm honored to be part of a really cool team of Test Engineers / Authors writing (Wrox). I'm not sure about similar books in the marketplace (one bad thing about writing is it consumes all my reading time!). This book is written for individuals and teams developing software using Visual Studio Team System. And it will help you understand when and why to test (before deploying, even!).

I know this is a great book - I've been reading the chapters as they're turned in! The other three authors are testing gurus. Not only are these guys very good Test Engineers, they're also cool people. It's been an honor to work with Tom, Dominic, and Mike.

This has been a fun writing project!

:{> Andy

Technorati Tags:

Applying SQL Server Service Packs and HotFixes

Some notes about the SQL Server Service Pack Installation Engine. I like it - a lot. The new engine goes to great lengths to prevent my having to bounce a physical server to apply a service pack. No matter how you slice it, it takes less time to stop and restart a service than restart the server.

You will reach a point in the installation where the following dialog displays:

If I were to suggest one change for the SQL Server Service Pack installer, I would suggest disabling the Next button until the check is complete on this "Checking for locked files" screen. A lot of people have been conditioned by disabled buttons to click-if-it's-enabled. So they see the Next button available and just click through this step. The step allows you to do this and stops the check for locked files. However...

  • Some Service Pack (or hotfix) patches may not be applied as a result.
  • You may be required to reboot the server to complete the Service Pack (or hotfix) installation.

So for now, no blindly clicking the Next button!

When locked files are discovered the dialog displays something like the following:

My advice: Stop here, open Services and stop each of the identified services manually. After each has been stopped, click the Refesh button and you should see the next screenshot:

If you do not see this screenshot, you haven't stopped all the impacted services. Rinse and repeat until you get a "No locked files found" message. Then click the Next button.

As installation progresses you will see a screen similar to the following:

This screen shows you what's being updated and gives an indication of progress. Progress indications good.

When the Installation Progress indicates all is complete, click the Next button to proceed. A summary displays all SQL Server-related services and their Service Pack / HotFix disposition:

Be sure to restart the services you manually stopped before proceeding!

This explains why some service pack installations don't "take." If you believe you've installed an SSIS SP, for instance, but are still seeing that pesky issue that was supposedly resolved, this could be why.

:{> Andy

Technorati Tags: SQL Server 2005 Applying Hotfixes Applying Service Packs SP2

posted Friday, March 09, 2007 9:01 PM by andy with 0 Comments

SQL Server 2005 SP2

There was a bug in the initial release of SQL Server 2005 SP2. One of the fixes added the "Hours" unit of measure to the enumeration of Maintenance Plan scheduling intervals. Something happened when adding the new item. Since "days" was previously the lowest unit of measure and "hours" was now the lowest unit of measure, days were converted into hours (kind of like the "by the book" scene in Star Trek 2: The Wrath of Kahn).

This was bad because stuff scheduled to run every day before applying the service pack was now running every hour after application.

Microsoft fixed the bug and re-released SP2. There's been some discussion about the manner in which they went about it but I will not delve into that here. It's fixed - let's apply the fix and move forward.

You can see information about the bugs fixed by reading . If you downloaded and applied SP2 before 5 Mar 2007, you only need to apply the . Read for details.

SQL Server 2005 SP2 RTM took several components to version 9.00.3042.00. The Ciritcal Update takes them to 9.00.3050.00.

Thanks to fellow Solid Quality Mentor Ashton Hobbs for pointing this out.

:{> Andy

Technorati Tags: SQL Server 2005 SP2 Hours Days Maintenance Plans

posted Friday, March 09, 2007 8:20 PM by andy with 0 Comments

Roanoke Code Camp - Time for me to present!

Well, I have to go prepare to present!

I may blog more later - if I don't, Robin Edwards and the Roanoke Code Camp team really did a great job!

:{> Andy

Technorati Tags:

Roanoke Code Camp - Rob Ericsson - SQL Server 2005 XML Datatype

Rob Ericsson is presenting on the xml Data Type in SQL Server 2005.

As I arrive, Rob is explaining xml data type conversions: you can convert from text to xml, but it's very difficult to convert back.

Rob dives into a comparison between SQL Server 2000 and SQL Server 2005 xml functionality. It's nice that SQL Server 2005 gives us the option of formatting the XML into elements - where we were limited in SQL Server 2000 to an attribute-based format. By adding ",xmlschema" to the query, we can generate a schema along with the data - how cool!

Rob is a great speaker!

:{> Andy

Technorati Tags: Roanoke Code Camp Rob Ericsson XML data type SQL Server

Roanoke Code Camp - Tim Tatum - T-SQL

Tim Tatum of Core Consulting is presenting Transact-SQL.

I met Tim and his lovely wife Sharon at the Speaker Dinner last night - they're good people.

Tim's a former school teacher who went back to school to obtain and MBA with an IT focus. I've met a lot of top IT professionals who were once in other careers and later moved to IT. In my opinion, these folks bring a diversity to the field like nothing else.

I learned Tim lives just up the road, so I've already bugged him (last night) about speaking at the Richmond UG meetings.

Tim is speaking on the fundamentals of SQL Server development and design. This is so very important. Why? Whenever I go to a new client who is experiencing performance trouble, inevitably they have designed something in violation of some fundamental.

Tim is, probably because of his teaching background, an excellent speaker! He breaks things down very well and has a soothing delivery style.

Good job, Tim.

:{> Andy

Technorati Tags: Roanoke Code Camp Tim Tatum Core Consulting

Roanoke Code Camp is Tomorrow!

I just got back from the Roanoke Code Camp Speakers Social - what a blast!

I met several of the speakers tonight and I am very impressed with the line-up!

If you haven't signed up yet there's still time! You can and show up tomorrow! It's going to be a beautiful day in the Star City tomorrow, and some serious knowledge will be shared by a stellar group of speakers!

I will be there, and hope to see you there as well!

:{> Andy

Technorati Tags: Roanoke Code Camp Developer Community Roanoke Valley SQL Server User Group Roanoke Valley .Net User Group

posted Saturday, March 03, 2007 12:15 AM by andy with 0 Comments

Everything Scales

The tune to a Bush song is running through my head as I type this... the band, not the president - although imagining the President singing the song is an interesting brain-stretch.

It's a fact of IT life that everything scales. Some successfully, even. Problems start when things do not scale successfully (or well). It happens in business. It happens with software systems.

When it happens with businesses, you hear things like "They grew too fast." When it happens with software systems, you browse to a website and receive an HTTP 500 or 404 error.

Can this be avoided (in business or software)? I think that's an excellent question - one well worth examining.


The answer, I believe, lies with how predictable the scalability is.

Consider a database application: If you know which tables are going to grow, how, and how much, you can plan for said growth. How would you plan? You could partition the tables using one or a combination of partitioning techniques. You could appropriate filegroups, snapshots, and a host of other functionality. If you only you knew where to apply these techniques.

That's the key.


Achieving scalability starts with capturing metrics. If you know how your database is growing from the beginning - if you can chart the growth of individual tables, access patterns, and internal performance data - you can predict growth and manage scalability.

So the key is measurement.

Measurement is an engineering discipline in its own right. The field of applied measurement is called Instrumentation. Applying measurement to a process is referred to as "instrumenting the process."

How do you instrument a database process? Iteration 1 would include creating an internal table to house and maintain process metadata:

CREATE TABLE dbo.ProcessData
(ProcessDataID int IDENTITY(1,1) NOT NULL,
ProcessDataDateTime datetime NULL CONSTRAINT DF_ProcessDataDateTime DEFAULT (getdate()),
ProcessDataIndicatorName varchar(50) NULL,
ProcessDataIndicatorValue varchar(50) NULL,
ProcessDataIndicatorStatus char(1) NULL CONSTRAINT DF_ProcessDataIndicatorStatus DEFAULT ('C'),
CONSTRAINT PK_ProcessData PRIMARY KEY CLUSTERED (ProcessDataID)

If your instrumented process is stored-procedure-based, you could add INSERT statements to your existing stored procedures. Consider instrumenting a parent stored procedure that calls child stored procedures. The instrumented proc could look like the following (instrumentation emphasized):

CREATE PROCEDURE dbo.SomeProcess
AS

begin

INSERT INTO dbo.ProcessData
(ProcessDataIndicatorName,
ProcessDataIndicatorValue)
VALUES('ChildProc1','Starting');


EXEC dbo.ChildProc1

INSERT INTO dbo.ProcessData
(ProcessDataIndicatorName,
ProcessDataIndicatorValue)
VALUES('ChildProc1','Ending');

INSERT INTO dbo.ProcessData
(ProcessDataIndicatorName,
ProcessDataIndicatorValue)
('ChildProc2','Starting');


EXEC dbo.ChildProc2

INSERT INTO dbo.ProcessData
(ProcessDataIndicatorName,
ProcessDataIndicatorValue)
VALUES('ChildProc2','Ending');

INSERT INTO dbo.ProcessData
(ProcessDataIndicatorName,
ProcessDataIndicatorValue)
('ChildProc3','Starting');


EXEC dbo.ChildProc3

INSERT INTO dbo.ProcessData
(ProcessDataIndicatorName,
ProcessDataIndicatorValue)
VALUES('ChildProc3','Ending');


end

Before moving forward, removing code duplication would be a worthwhile effort. In application development, this is one of many processes generally referred to as Refactoring.

The INSERT statements are a prime candidate for refactoring and we can address this with a stored procedure:

CREATE PROCEDURE dbo.AddProcessData
@ProcessDataIndicatorName varchar(50),
@ProcessDataIndicatorValue varchar(50)
AS

begin

INSERT INTO dbo.ProcessData
(ProcessDataIndicatorName, ProcessDataIndicatorValue)
VALUES(@ProcessDataIndicatorName, @ProcessDataIndicatorValue);

end

Now the parent stored procedure instrumentation above can be modified to look like this:

CREATE PROCEDURE dbo.SomeProcess
AS

begin

EXEC dbo.AddProcessData @ProcessDataIndicatorName='ChildProc1', @ProcessDataIndicatorValue='Starting';

EXEC dbo.ChildProc1

EXEC dbo.AddProcessData @ProcessDataIndicatorName='ChildProc1', @ProcessDataIndicatorValue='Ending';

EXEC dbo.AddProcessData @ProcessDataIndicatorName='ChildProc2', @ProcessDataIndicatorValue='Starting';


EXEC dbo.ChildProc2

EXEC dbo.AddProcessData @ProcessDataIndicatorName='ChildProc2', @ProcessDataIndicatorValue='Ending';

EXEC dbo.AddProcessData @ProcessDataIndicatorName='ChildProc3', @ProcessDataIndicatorValue='Starting';


EXEC dbo.ChildProc3

EXEC dbo.AddProcessData @ProcessDataIndicatorName='ChildProc3', @ProcessDataIndicatorValue='Ending';

end

Much better.

Measuring the current process provides a baseline - the first step in a continuous improvement process that will provides dynamic design changes, performance monitoring, and - eventually - a dynamically-scalable system. It also supplies the current performance status against which we can benchmark future improvements and modification.

:{> Andy

Technorati Tags: Bush Scalability Database Instrumentation

Vista and SQL Server Mixed-Mode

I've been traveling the continent the past few months warning people of the evils of SQL Server Mixed Mode authentication. I recently (this past weekend) procured a snappy new Gateway laptop with Vista installed.

It turns out SQL Server 2005 installed on Vista does not automatically add members of the local Administrators group to the SQL Server role BUILTIN\Administrators. Rather than waste lots of time reading the readme files, I discovered this when I tried to connect to freshly-installed SQL Server instance.

So after re-installing SQL Server in Mixed Mode and logging in as sa, I was able to add myself as a sysadmin. Afterwards, I changed the instance from Mixed Mode to Windows Authentication. Windows Authentication is still more secure.

Thank you, Slammer worm...

:{> Andy

Technorati Tags: SQL Server 2005 Vista Mixed Mode Windows Authentication security Slammer

I will present SQL Server Tips and Tricks 8 Feb 2007

After the Freezing Redneck Tour 2007 wraps up this week, I'm looking forward to the next meeting of the Richmond SQL Server Users Group.

I've decided to present on SQL Server Tips and Tricks. I have three topics in mind:

  • SqlClr
  • An Introduction to Incremental Data Warehouse ETL with SSIS
  • A surprise topic!

Trust me, if you work with SQL Server data warehouse ETL you will like the surprise. ;)

Hope to see you there!

:{> Andy

Technorati Tags: Developer Community Richmond SQL Server Users Group SqlClr Incremental ETL

SQL Programmability and API Development Team Blog

If you work with SQL Server and haven't checked out the SQL Programmability and API Development Team Blog, you should. Now. Immediately. I'm not kidding.

It's simply awesome!

:{> Andy

Technorati Tags: SQL Server Programmability API Development blog

SQL Snack

...from theDailtyWTF: Chocolate Covered SQL


...spaces in the table and field names. Easier to read or just three extra characters to type?

Thanks Frank for sending me this!

:{> Andy

Technorati Tags: SQL humor raisins chocolate

posted Thursday, January 18, 2007 10:06 PM by andy with 0 Comments

A couple changes!

I've started a new blog: Applied Business Intelligence!

I will continue to blog here about Team System topics. I'll probably continue to share personal stuff here as well - I'm debating that...

I've also changed my login here at VSTeamSystemCentral.com. I'll no longer be posting as that dry and boring "admin" guy - now I'll be posting as me!

:{> Andy

Technorati Tags: New blog Applied Business Intelligence BI SSIS ETL Reporting Services

posted Tuesday, January 16, 2007 10:45 AM by andy with 0 Comments

Randy Franklin, SQL Server Notification Services, Tonight!

Randy Franklin presents an introduction to SQL Server Notification Services tonight at the January Meeting of the Richmond SQL Server Users Group!

The meeting will be held at the Markel Facility, 4600 Cox Road, Glen Allen. It starts at 6:30 PM and the public is invited.

Randy has been digging into SSNS for a while now and shares tips and tricks about this service for SQL Server 2005. Come on out this evening - bring a friend!

The pizza is free!

This month's sponsor is
Richmond Code Camp 3!
Richmond Code Camp 3!

Richmond Code Camp 3 will be held 28 April 2007 at ECPI-Innsbrook.

:{> Andy

Technorati Tags: Developer Community SQL Server Users Group Notification Services Richmond Code Camp

posted Thursday, January 11, 2007 7:56 AM by admin with 0 Comments

2006 - the Year in Review

This is probably my last post of 2006. It's been a good year. Not perfect, but very good.


got lots of traction in the industry. Most SQL Server technologists I know agree five years was a long time to wait for a new release, but the feature set matches or exceeds the development effort.

Most shops I deal with have either migrated, are testing 2005, or have plans to in 2007.

was released and Service Pack 2 is on its .

- aka Data Dude - went from CTP1 to RTM in six months. Very impressive development cycle!


It's been a good year for the Richmond Developer Community.

We started a new SQL Server Users Group, which is now the official PASS chapter for Richmond, VA! We also held two successful MSDN Code Camps - and the leadership team is planning more for 2007.

Speaking of leadership, the team did an outstanding job in 2007 - thanks to all who led and participated at every level! You folks rock!


Personally, it's been a good year too.

Christy and I bought a house in Farmville, VA - completing our move from Jacksonville, FL back home to Virginia.

We recently learned we're going to be parents again! :)


Business-wise, it's also been a cool year.

I moved from a temp-to-perm position to a permanent consulting gig, and was then recruited by Solid Quality Learning! The relationship with Solid Quality allows me to be an independent consultant. It's nice to be working for me again, although my boss is sometimes a jerk... ;)

I learned a couple difficult lessons as well. Without going into detail, suffice it to say this year affirmed my long-held business standards regarding the importance of integrity, loyalty, and trust. At my age and with my experience with people and in the industry, I am not often surprised by people - but I was surprised this year. My lovely bride Christy has an applicable saying about such times: "Good judgment comes from experience, and experience comes from bad judgment." Amen. I believe it is best to always treat people as you want to be treated because you never know...

I also experienced new levels of trust and respect. I worked with an incredibly talented team on a cool project. Loyalty was a hallmark of our experiences on the team. The result? Against seemingly insurmountable odds and obstacles, both internal and external, we succeeded - and made it look easy! My experiences at Solid Quality Learning have underscored the value of loyalty and integrity in all we do. The professionals that lead this company are at once the most talented, intelligent, down-to-earth, humble, and open people on the planet. It is an awesome honor to be part of this organization!

I was honored several times this year:

  • one of the authors of (Wrox)
  • allowed to participate on the leadership team for the Code Camps
  • honored to lead the Richmond SQL Server Users Group
  • honored to lead the Richmond .Net Users Group
  • nominated for MVP
  • honored to deliver the Team Edition for Database Professionals keynote at the Philadelphia Launch Event
  • honored to be invited to Redmond several times to participate in TAP and certification discussions
  • honored to work with a fantastic team to develop an industry-changing application (which I cannot talk about!)
  • honored to be asked to join Solid Quality Learning as a mentor

I don't do resolutions, I merely set goals for the forseeable future. I was able to accomplish two of three goals I set at the end of last year. I find three is a nice round number for goals - and I am working on my three goals for 2007 this last afternoon of 2006.

Here's to 2007 - may you have a safe, prosperous, and happy new year!

:{> Andy

Technorati Tags: 2006 Year in Review trust Solid Quality Learning integrity new baby 2007

posted Sunday, December 31, 2006 4:44 PM by admin with 0 Comments

VarDecimal in SP2 (December CTP)

I've been experimenting with the new VarDecimal data type in SP2.

In a virtual PC named vpcPeter (there's a vpcRay and vpcEgon nearby), I deployed the December CTP of SP2. I then created a database named StorageTests and a table inside named dbo.VarDecimalTest.

I wrote a routine that populated a decimal field in dbo.VarDecimalTest with 10,000 rows of decimal(18,5) data type.

I next enabled the vardecimal datatype for the database using exec sp_db_vardecimal_storage_format 'StorageTests', 'on' and executed the test sproc (exec sys.sp_estimated_rowsize_reduction_for_vardecimal 'dbo.VarDecimalTest') to estimate row_len savings:

29.47 / 32.87 ~= 0.8966 equating to a roughly 10% reduction in data table size.

I then enabled the varDecimal data type on the table with the following command: sp_tableoption 'dbo.VarDecimalTest', 'vardecimal storage format', 1. Note that this does not add a new data type per se (executing select * from sys.types still returns only 27 rows...) but it converts existing decimal / numeric rows in the specified table to the new data type - saving space:

Before:


After:

The script I used to generate these results is available here.

My original table is 352 KB, my VarDecimal table table is 312 KB. 352 * .8966 = 315. Pretty darn close.

:{> Andy

Technorati Tags: SQL Server VarDecimal 2005 SP2 December CTP

posted Wednesday, December 27, 2006 1:04 AM by admin with 0 Comments

SQL Server 2005 SP2 December CTP released

The SQL Server 2005 team has released .

Some cool fixes are in this release including:

  • A new datatype for the Enterprise Edition database engine: vardecimal. Similar to varchar, this datatype stores only the precision required by the value. There's even a stored procedure included to estimate the reduction in average row size. Cool!
  • Maintenance Plans can now be executed without installing SSIS. Although Maintenance plans remain SSIS packages, selecting the Database Engine option during installation includes the Integration Services execution engine.
  • Logon Triggers!
  • The ability to return text XML query plans when the XML contains more than 127 nested levels.

Some nice touches for SSIS include:

  • The BypassPrepare property of the Execute SQL Task now defaults to True. (Thank you)
  • A new property - ParameterSize - for string parameters in the Execute SQL Task.
  • More variable comboboxes - less variable textboxes.

There are enhancements and improvements to other SQL Server components including:

  • Scripting
  • Management Studio Reports
  • Database Mail
  • The Copy Database Wizard
  • Backup and Restore
...just to name a few!

:{> Andy

Technorati Tags: SQL Server 2005 SP2 December CTP

Team Edition for Database Professionals Launch Events!

The Philadelphia Launch Event for Team Edition for Database Professionals was a blast!

The crowd was awesome and very engaged. They added insight, made great suggestions, and asked some good questions - it was obvious most folks are excited about the product. From my informal poll, others present are taking a wait-and-see stance.

I hear both groups! I'm excited about the options and support the product enables for database developers, but I also understand the cautious response from most operational (system) DBAs.

I need to write more about this (when I have more time to blog!), but the same traits that make the operational DBA very good at their job also make them very resistant to change. I am working on ways to implement the cool new features of Team Edition for Database Professionals into the daily life of the operational DBA without upsetting the apple cart. To this end, I'm working with some of the smartest operational DBA types on the planet.

I don't believe adoption will be an issue on the developer side of the house. And, even if the product is not adopted into the operational DBA toolkit, it will still make their lives easier beacuse database developers and developers developing database object (yes, there is a difference) will now have integrated testing at their fingertips. Regression testing will become part of the DDLC (Database Development LifeCycle).

More later...


If you're in the mid-Atlantic region and haven't already registered, you can scheduled for Tuesday 5 Dec 2006 at the Grand Hyatt located at 1000 H Street, NW in DC.

:{> Andy

Technorati Tags: Data Dude Team Edition for Database Professionals Launch

posted Saturday, December 02, 2006 12:57 PM by admin with 0 Comments

I'm a Mentor!



My Solid Quality Learning business cards arrived in the mail yesterday. I like my new title: Mentor.

I believe the title is appropriate for the mission of Solid Quality Learning which is summarized:
Solid Quality Learning is the trusted, global provider of advanced education and solutions for the entire Microsoft database platform.

Cool.

:{> Andy

Technorati Tags: Solid Quality Learning SQL Mentor

The Clean Break

For the first time since 2001, I find myself sitting behind the president's desk in the global headquarters of my own business!

The new venture is called Andy Leonard Technologies, Inc. and this my first full-time day on the new office.

I mostly perform work for Solid Quality Learning as a mentor. For those who are unfamiliar with S. Q. L., it's a fantastic company! Not only are the people industry-recognized experts, they're actually cool! They engineer the entire process of joining their ranks so that it's low-stress. It has allowed me to ramp up quickly - and for that I am very thankful.

Mentoring is a great concept - it's a hybrid between consulting and instructing. Here's how it works: I join teams for a number of days or weeks. While working together, we develop a specific set of objectives - usually to develop template projects, best practices, and establish a foundation for the working environment. Together, we build out example projects using the templates to demonstrate their effectiveness.

In addition to this, I'm also a trainer. When training, I lead excellent classroom-based instruction courses. I currently lead the ETL with SSIS course, but I am ramping up on more course material - hoping to lead others.

In my previous jaunt into business, I operated ASI. ASI specialized in industrial automation and integration. It was a lot of fun for me because it brought together several disciplines I enjoyed (and still enjoy!): engineering, electrical control systems design, and software development.

ASI started in 1995 when I wrote one of the first completely web-based Manufacturing Execution Systems (MES) called Plant-Wide Webs. Plant-Wide Webs started using dynamic HTML before DHTML was widely available, then graduated to ASP. Writing the application and running the business were cool experiences!

I learned a lot about business and myself. :)

Most of those lessons were learned the hard way. I remember looking at the checking account one day during my first few months of entrepreneurship and seeing $80 in there. I thought "I must've done something stupid." I was right, and this was the beginning of my understanding of business development.

When Solid Quality Learning called I was ready. I understood the risks of making the leap. I knew it would be a lot of hard work. But, unlike last time, this time I have a fantastic team supporting me - and outstanding business development support!

The person who deserves the most credit has to be Christy. Not only does she support this decision, she's actively involved - booking my flights, making hotel arrangements, and renting cars... she's awesome! She even jumps onto mapping software and talks me in from the airport to the hotel so I don't drive around lost my first night in a new town! (The car rental people always ask "Do you know where you're going?" and look at me funny when I say "No, but I'll find it!") Christy does this in addition to taking care of Stevie Ray and Emma without help from me (when I'm out of town or holed up in the office) - and she does it without complaining.

Thanks, Cutie. I couldn't do this without you!

It feels good to be back. So far, the new boss is treating me ok... but it's still early on the first day... ;)

:{> Andy

Technorati Tags: Andy Leonard Technologies, Inc. Self-employment SQL Server Solid Quality Learning SQL

posted Monday, November 20, 2006 4:14 PM by admin with 0 Comments

Study: SQL Server is Safest Database

According to this report, SQL Server is the safest database engine on the market.

Security Vulnerability Count

  • Oracle: 70
  • MySQL: 59
  • Sybase: 7
  • DB2: 4
  • SQL Server: 2

I don't even have to search for them to know there are already howls of protest from Sybase, DB2, MySQL, and Oracle DBAs. I understand, truly I do.

Again, I haven't read the protests or complaints. I simply know the responses - because for years I've felt the same way when someone poked holes in my favorite database engine, SQL Server.

It's not that the holes don't (or didn't) exist - it's that these sorts of tests usually ignore the value any DBA brings to the table. The DBA knows about the vulnerabilities - at least the good one's do - and how to configure the system to be less vulnerable.

So Oracle, Sybase, DB2, and MySQL DBAs (once more, without even bothering to search), I understand.

Next time someone posts something about SQL Server, I expect you to also understand.

(... off to search for the responses now...)

:{> Andy

Technorati Tags: SQL Server Security Oracle DB2 MySQL

posted Monday, November 20, 2006 3:56 PM by admin with 0 Comments

Team Edition for Database Professionals RTM 30 Nov 2006!

Grant Fritchey posts an excellent article about database Unit Testing with Visual Studio at SQLServerCentral.com.

Grant begins the article with a lament regarding all his work to automate unit testing using TSQLUnit and CodeSmith - only to have Team Edition for Database Professionals come along and integrate this functionality into Team Suite! I nearly shared the same fate.

Earlier this year, I was ready to start a community initiative to develop a plugin for Visual Studio and/or Team Foundation Server that would facilitate automated database testing. My logic: This was long overdue. As a web developer in pre-.Net days, I could practice test-driven development. I found TDD added a self-organizing emphasis to my thinking and work.

When I became a database developer, I searched for similar tools and methodologies for my database objects. To my shock and dismay, there were none. Since that time I've found some but they lacked the crucial integration component I sought.

(aka TEDP or Data Dude) - about to be officially !

Yours truly will be delivering the keynote at the Philadelphia Launch Event that very day!

Database development increasingly consumes more enterprise project development life-cycle time. As application developers take advantage of agile methodologies and development tools like Visual Studio Team Suite, their portion of the development lifecycle improves in quality and takes less time. It was all we poor database developers could do to keep up - and usually we needed to be ahead of the application developers (so they would have data to work with!).

Now, we have a fighting chance.

:{> Andy

Technorati Tags: Team Edition for Database Professionals TEDP Data Dude RTM Test-Driven Development SQL Server Test-driven database development

posted Wednesday, November 15, 2006 10:37 AM by admin with 0 Comments

Microsoft SQL Server 2005 SP2 CTP

Microsoft announces the release of .

There are versions for different editions of SQL Server 2005:

:{> Andy

Technorati Tags: SQL Server SP2 CTP

posted Friday, November 10, 2006 2:03 PM by admin with 0 Comments

SQL Server 2005 Compact Edition RC1

Microsoft announces the release of - formerly named SQL Server Everywhere Edition. You can download it .

One nice feature is ClickOnce support. There several steps you must take to enable ClickOnce in this edition (perhaps another blog entry...). But the work will be worth it if ClickOnce works as advertised (I haven't tested it).

:{> Andy

Technorati Tags: SQL Server Compact Edition Everywhere Edition ClickOnce

posted Friday, November 10, 2006 1:55 PM by admin with 0 Comments

Page Vest and SQL Server 2005 Service Broker

Page Vest did an outstanding job last night at the Richmond SQL Server User Group! His presentation on SQL Server 2005 Service Broker was well-received by all in attendance.

He did a good job digging into the inner workings of queues. I learned something: there's a system queue (sys.transmission_queue) where all messages land before moving to the destination queue. The reason? The destination queue may be disabled.

Page covered that and much more - good stuff!

:{> Andy

Technorati Tags: Developer Community SQL Server Service Broker Richmond, VA Page Vest

posted Friday, November 10, 2006 11:05 AM by admin with 0 Comments

Richmond SQL Server Users Group Meeting tonight!

Page Vest speaks on SQL Server 2005 Service Broker at the November meeting of the Richmond SQL Server Users Group.

Fahrenheit Technology sponsors this month's meeting - be sure to thank them for arranging the meeting room, providing pizza and sodas, and their continued support of the Richmond Microsoft developer community.

I look forward to learning more about this exciting enhancement to SQL Server 2005!

Hope to see you there tonight!

:{> Andy

Technorati Tags: Developer Community SQL Server Users Group Richmond, VA Service Broker

posted Thursday, November 09, 2006 2:38 PM by admin with 0 Comments

FAQ Friday

I was honored to be G. Andrew Duthie's guest today on FAQ Friday. (I know, "next time post something before the event, Andy.")

Thanks Andrew for asking to be on the webcast!

We talked about SQL Server Integration Services, Team Edition for Database Professionals, Team Foundation Server, and SQL Server 2005. We managed to get in some tips and tricks for the query window in SQL Server Management Studio, including viewing and executing SQLCmd statements in an SSMS query window.

FAQ Fridays rock!

:{> Andy

Technorati Tags: FAQ Friday SQL Server Integration Services Management Studio SQLCmd

posted Friday, October 27, 2006 4:16 PM by admin with 0 Comments

SQL Server Hosting Toolkit

Microsoft announces the SQL Server Hosting Toolkit.

It's a command line-based scripting tool. This is the first CTP so it's limited in proposed functionality - but even so, it's already impressive.

After installing the utility, access it from the Start menu:

I immediately aimed it at AdventureWorks in a local instance of SQl Server 2005 on my laptop - hoping to generate a database script. It failed:

At this point, I decided to read the ReadMe file:

There's a link to Known Issues which took me to a page describing supported database objects and unsupported data types. The returned error listed the database table where the issue originated (nice touch!): DatabaseLog. It turns out DatabaseLog contains an XML field - one of the unsupported types.

To test, I first created a database and added one of each supported database object - a table, index, view, and stored procedure:

I added data to the table with an index, created a view that returned SELECT *..., and created a sproc that accepted a single parameter (id) and returned everything in the view. After test execution of the sproc, I used SQLPubWiz to generate scripts for the database:

I next deleted the objects I created earlier and used the generated script to recreate them. Executing the sproc returned an error - it no longer existed.

One cool feature I noticed right away is the data in the table is also included in the script. Re-executing the sproc proved the database and data had been restored.

Technorati Tags: SQLPubWiz SQL Server Hosting Toolkit SQL Server Utilities

posted Sunday, October 22, 2006 12:39 AM by admin with 0 Comments

Team Edition for Database Professionals CTP6!

was released Wednesday.

As with previous versions - notably CTP5 - projects built in previous versions will not load properly in CTP6. "Breaking features" were added and they're common in CTPs. It beats the alternative of no CTPs, so no whining!

One note: Connection passwords are stored in the registry - although encrypted - whether you check the "Save my password" checkbox or not. There are a few other gotchas, but they're documented in the ReadMe.

In a related note, Microsoft has started scheduling launch events for Team Edition for Database Professionals! Sign up today!

:{> Andy

Technorati Tags: Team Edition for Database Professionals Data Dude CTP

posted Friday, October 20, 2006 10:18 AM by admin with 0 Comments

MSDE will not run on Vista

Microsoft announced .

And not just that - MSDE will also not be supported on Vista.

If you're using MSDE in your apps, it's a good time to start looking at .

:{> Andy

Technorati Tags: SQL Server MSDE SQLExpress SQL Express

RCC2-10 days: Countdown to Code Camp

Richmond Code Camp 2 approaches!
Have you ?

Only 1010 (decimal, lest you bit-heads think I mean there are only 2) days remain until the second Richmond MSDN Code Camp! (That's 10102 days for youwe bit-heads.)

The schedule has been posted!

:{> Andy

Technorati Tags: Developer Community Code Camp Richmond, VA

posted Wednesday, September 27, 2006 11:27 PM by admin with 0 Comments

SQL Server Agent JAM: The Job Activity Monitor

SQL Server 2005 ships with a nifty tool for monitoring SQL Agent jobs: the Job Activity Monitor.

To reach the Job Activity Monitor, open SQL Server Management Studio (SSMS), connect the Object Explorer to a Sql Server instance with SQL Agent installed, and expand the SQL Server Agent node in Object Explorer:

Double-click the Job Activity Monitor node to open, or right-click and select View Job Activity:

The Job Activity Monitor displays (Icon and Status indicate job is currently executing):

Right-click a job for a context menu. You can start a job from the Job Activity Monitor:

When the job completes, Last Run date and time are updated:

You can refresh the view manually or set auto-refresh options by clicking the View refresh settings link:

You can set the auto-refresh interval:

Click the View Filter link to filter jobs to view:

You can also start a SQL Agent job at a specific step:

Select a start step and click the Start button:

The job executes from the selected step:

You can access historical job run data:

The Log File Viewer is a powerful and flexible utility in its own right:

Job properties may also be displayed for editing:

Job properties:

The Job Activity Monitor serves as a cool hub for all SQL Agent Job-related tasks. Kudos to the Microsoft developer team for providing such a snappy utility.

:{> Andy

Technorati Tags: SQL Server SQL Agent Job Job Activity Monitor

posted Wednesday, September 27, 2006 11:26 PM by admin with 0 Comments

Follow-up #2 to Database Professionals: An Enterprise Requirement

Eric Wise drew some heat from the developer community at CodeBetter.com with this post about the need for a DBA during development (see my post on the subject here).

I think Eric makes a couple good points, one explicitly and one implied:

1. (Explicit) A DBA - or Database Developer, more accurately (and there is a difference) - adds value to development.

2. (Implicit) There are Software Developers out there who can step into the Database Developer role long enough to solve most database tuning issues. Eric demonstrates this with himself in profiling and addressing a missing or ill-defined index.

I find most of the comments - presumably by software developers - typical. One developer stated:

My current project didn't have a DBA for 2 years, until recently since we're now at the stage of optimizing for performance. It seems to me that as long as the database is intelligently structured in the first place, a DBA's role would be rather small in most cases.

I agree with the sentiment expressed here - as much as I agree that code-generation tools can replace developers. It's true that you can utilize SQL Server or any database engine as a dumb file store. And it's equally true that you can build an enterprise application in C# that consists of thousands upon thousands of lines of nested If... Then... Else statements.

The question is: Why would you?

This goes beyond arguments over syntax, coding standards, methodology, and design philosophy. This is about putting competent professionals - at the height of their game - into the mix on a project.

You don't have to take my word for it - ask software developers who have worked (or are working) with competent database developers.

:{> Andy

Technorati Tags: Developer Community software developers DBA database developers SQL Server

Right on, Steve! (Giving back)

(Yes, I'm stating something about my age by utilizing the phrase "right on.")

Steve Jones has a great editorial about giving back to the developer community in this morning's SQL Server Central newsletter. Check it out here. I couldn't agree more!

:{> Andy

Technorati Tags: Developer Community MVP giving back writing PASS

posted Thursday, August 24, 2006 10:33 AM by admin with 0 Comments

Team Edition for Database Professionals CTP5 is available

Download it at the !

Note: Projects created in previous versions of TEDP will not open in this version - you must recreate them in CTP5.

:{> Andy

Technorati Tags: Team System Team Edition SQL Server Team Edition for Database Professionals CTP5

posted Wednesday, August 23, 2006 2:28 PM by admin with 1 Comments

Free! (for 180 days...)

I regularly speak to folks who tell me they wish someone would give them an MSDN subscription so they could play with all the cool new technology. I sincerely hope every single person with this desire gets their wish - if not from an individual (as happened to me), from their company. An MSDN subscription is a cool thing.

Until then, I recommend folks do what I did: get the trial versions!

You can build yourself a handy little enterprise on a workstation that has 1G RAM and some hard drive space. It won't be fast, but you can learn cool things nonetheless. Here's how:

1) Download and install  - it's completely free (as in beer). With this snappy software you can create virtual machines on your workstation and install any operating system you desire. Use Virtual Server to do just that - build a virtual machine before proceeding.

2) Download the 180-day trial version of . Install this as the operating system on your new virtual machine.

3) Download the 180-day trial version of . Install this on your new VM.

4) Download the 180-day trial version of . Install this on your new VM.

There you have it - a development virtual workstation that will allow you to learn and grow and try cool new things, for the next six months, at least!

:{> Andy

Technorati Tags: Developer Community VS2005 Visual Studio SQL Server SQL SQL2k5 Virtual Server MSDN Windows Server 2003 2005

posted Wednesday, August 23, 2006 10:34 AM by admin with 0 Comments

ECPI .Net Users Group Presentation Last Night

Thanks to the ECPI .Net Users Group for inviting me to speak last night. :) The group in attendance was awesome!

My presentation on Beginning SSIS Development went well. I look forward to returning to present to this group, the newest of Richmond's Microsoft User Groups!

:{> Andy

Technorati Tags: Developer Community SQL SSIS ECPI .Net Users Group

dsKUcXswAz5ndk5

posted Friday, August 18, 2006 2:18 PM by admin with 0 Comments

SS2k5 Replication bug "Merge Agent failed" (MSSQL_REPL-2147199402)

I have more than one merge publication configured on a SQL Server 2005 SP1 server. One of the publications replicates a couple stored procedures. All subscriptions fail occassionally. The use case is remarkably similar to .

Every other Sunday (yeah, I know, Sunday... Murphy's Law strikes again...) replication on the stored procedures publication fails with the following error:

The Merge Agent failed after detecting that retention-based metadata cleanup has deleted metadata at the Publisher for changes not yet sent to the Subscriber. You must reinitialize the subscription (without upload).  (Source: MSSQL_REPL, Error number: MSSQL_REPL-2147199402)

Screenshot:

The identifies this as a bug to be addressed in SP2 and prescribed a workaround:

1. Right-click the publication and click Properties:

The "Subscription expiration" defines the retention interval discussed in the . Set it to a high number of days (or weeks, months, or years) to avoid this issue until SP2 is released: 

Click OK to continue. Right-click the subscription again, and this time click "Reinitialize All Subscriptions":  

The Reinitialize Subscription(s) dialog displays. Uncheck the "Upload unsynchronized changes before reinitialization" checkbox. Select the "Use a new snapshot" option and check the "Generate the new snapshot now" checkbox:

Note: "Reinitialize All Subscriptions" only reinitializes subscriptions to the selected (right-clicked) publication. It does not reinitialize all subscriptions to all publications.

Click the "Mark For Reinitialization" button. This should take care of it until SP2 is released!

The downside: you have to monitor your subscriptions to see when they haven't synchronized within the desired interval. Replication Monitor is a great utility for this and you can sort on the Last Synchronization column to check the last synch interval. To start Replication Monitor, right-click the Replication node in Object Explorer and click Replication Monitor:

I profiled Replication Monitor, snagged the SQL Replication Monitor executed, and created a couple custom Reporting Services reports to help me keep an eye on the situation. The stored procedure I started with was:

exec [distribution].sys.sp_replmonitorhelpsubscription @publisher = N<server_name>, @publication_type = 2, @mode = 0, @exclude_anonymous = 0, @refreshpolicy = N'0'

:{> Andy

Technorati Tags: SQL Server Merge Replication SP2 Merge Agent failed -2147199402 

Tuning SSIS

Elizabeth Vitt - along with Donald Farmer, Ashvini Sharma, and Stacia Misner - provide an excellent look inside the SSIS engine in this article: .

:{> Andy

Technorati Tags: SSIS performance tuning

posted Tuesday, August 08, 2006 12:29 AM by admin with 0 Comments

Database Professionals Required - A Followup

There's been some interesting responses to my earlier post Database Professionals: An Enterprise Requirement.

Brian Kelley, noted author and database guru, expanded on the post twice: first in Does your organization need a DBA? and again in Does your organization need a DBA? (Part 2).

Frank La Vigne responded from the developer perspective with Yes, You Do Need a DBA.

:{> Andy

Technorati Tags: Database Professionals Need a DBA SQL Server Frank La Vigne Brian Kelley

posted Wednesday, August 02, 2006 1:11 AM by admin with 0 Comments

Team Edition for Database Professionals Webcasts

Thomas Murphy, Team Edition for Database Professionals Group Program Manager, did a great job today with the first of a series of four webcasts on the product.

There's more to come. If you're interested in learning more about this field-altering product, I urge you to .

:{> Andy

Technorati Tags: Team Edition for Database Professionals Data Dude MSEvents MSDN Webcast

posted Wednesday, August 02, 2006 1:00 AM by admin with 1 Comments

Team Edition for Database Professionals WebCast tomorrow

Microsoft is webcasting about Team Edition for Database Professionals tomorrow at 11:00 AM PDT. .

More cool webcasts are scheduled - .

:{> Andy

Technorati Tags: Team Edition for Database Professionals Team System DBAs Team Edition webcast

posted Monday, July 31, 2006 4:18 PM by admin with 0 Comments

Database Professionals: An Enterprise Requirement

A friend (who shall remain nameless) recently told me his company interviewed a competent database developer and DBA. All seemed in agreement an offer would be forthcoming until the very end of the recruiting process. At that time, someone made the comment "we don't need a DBA."

It would be notable if this sentiment wasn't so widespread - but I see it often. How often? Well, I would have to tell you how I see it to qualify that statement:

You see, people rarely say to me "We don't need you because we don't need a DBA." Mostly I see it in their applications - many of them prominent companies in which you may even own stock. I can tell when I examine their schema. I can see it when I execute Profiler against their SQL Server database.

Now, there are lots of reasons to design a denormalized schema. And there are lots of reasons to encapsulate the business rules in code. This is not what I'm talking about - though some of these systems would clearly perform better (or at all, in extreme cases) if they took advantage of better design patterns.

I'm talking about designs where this much is obvious:

1. At least two people designed the data layer; and
2. They did not communicate during the process.

Often, enterprise-level database design is shoveled onto developers as a secondary task. No, I'm not making this up - it's too tragic to joke about. There are developers out there who can handle this task, but they are few and far between. (Before I became a SQL Server DBA I was a developer who thought I was a SQL Server DBA...)

There will doubtless be readers who can provide examples of how their enterprise application was built by junior developers who did the database and code work and whose systems are performing just fine. I'm happy for you and sincerely hope the system scales. 

Designing a scalable solution  - database, application, or architecture - is one of those things that consumes time, thinking, resources, and money during the early phases of an enterprise development cycle. But it is - hands down - one of the best (if not the best) investments in the solution. And in today's market, scalability is as optional as security. And like security, a scalable design is not something you "add later." It's not part of the foundation - it is the foundation.

My experiences with designing scalable solutions has proven to me there is no free lunch nor any shortcuts that work. If anyone - me included - skips the work of designing for scalability, there comes a day when they (or I) must pay the fiddler. From what I hear and have experienced, designing in this fashion is most often sacrificed on the altar of a deadline. Trust me, if it falls apart in six weeks or six months, you haven't saved any time - and you may have lost a customer.

Someone told me this and I remember because it has proven true several times over: "Deliver quality late, no one remembers. Deliver junk on time, no one forgets."

If you're building (or upgrading to) cutting edge technology, you need a DBA.

:{> Andy

Technorati Tags: Software Business scalable database design quality

Team Edition for Database Professionals (Data Dude): Cool Channel9 Video

Some of the development team for Team Edition for Database Professionals (Data Dude) appear in a 52 minute demo video of the product on Channel9.

Definitely worth watching!

:{> Andy

Technorati Tags: Developer Community Team Edition for Database Professionals Team System MSDN Channel9

Donald Farmer is blogging again

Donald Farmer, Microsoft's Group Program Manager for SQL Server Business Intelligence and Integration Services, is blogging again!

Mr. Farmer is a legend in the business intelligence community. Even so, he's always made time to answer questions from this aspiring author.

His post entitled Tales of Two Bills is an interesting read.

:{> Andy

Technorati Tags: Developer Community Donald Farmer SSIS blogs

posted Sunday, July 16, 2006 6:14 PM by admin with 0 Comments

Last night's meeting of the Richmond SQL Server Users Group

We had an awesome meeting last night! There must have been 25 people there and it was a great audience - lots of good questions and feedback.

As promised, here's the - now up to CTP4 in only a month! Great job, Team Edition for DBAs Team!

:{> Andy

Technorati Tags: Developer Community SQL Server Users Group Richmond, Va Team Edition for DBAs Team Edition Database Professionals

posted Friday, July 14, 2006 1:47 PM by admin with 0 Comments

Richmond SQL Server Users Group - July meeting

I'll be speaking at the July meeting of the Richmond SQL Server Users Group tomorrow night. The topic is "Introduction to Team Edition for Database Professionals." I plan to cover Schema Compare and Refactoring functionality.

Hope to see you there!

:{> Andy

Technorati Tags: Developer Community Richmond, VA SQL Server Users Group Team System Team Edition for Database Professionals

posted Wednesday, July 12, 2006 9:48 AM by admin with 0 Comments

Copying Data From SSMS data grid

Just a quick entry here to thank the good people on the SQL Server 2005 developer team for the ability to copy data from a cell in the SSMS data grid onto the clipboard and paste it without an appended line feed.

Bless you.

:{> Andy

Technorati Tags: SQL Server 2005 copy paste data grid

posted Wednesday, June 28, 2006 5:56 PM by admin with 0 Comments

The Team Edition for Database Pro's bits are live!

The Team Edition for Database Professionals CTP is !

:{> Andy

Technorati Tags: Team Edition Database Professionals SQL Server

posted Monday, June 12, 2006 11:19 PM by admin with 0 Comments

Sneak Peek at Team Edition for Database Professionals

Update: I am working on demos and walk-throughs of Team Edition for Database Professionals for VSTeamSystemCentral.com. (it's free - and relatively painless) for updates.


Thanks to Tom Murphy, a member of the team at Microsoft, I was able to get a sneak peek at the product earlier this week.

First impression: "Wow!" :)

This is something to behold. Two features immediately impress: Data Generators and Test Projects.

Test Projects provide database developers test-generation functionality very similar to that now enjoyed by C# and VB.Net developers using Team System. I got all giggly inside when Tom navigated to a stored procedure, right-clicked, selected Generate Test (or something close, I can't remember) - and SQL appeared that would test the procedure's output! Below this, a frame contained "assert" conditions and expected conditional results. Truly remarkable, truly awesome. Good job development team!

Data Generators provide a way to automatically populate a database with gibberish. "Well what good is gibberish, Andy?" I'm glad you asked. Gibberish, it turns out, is a highly prized commodity in the land of SOx. The good people who perform SOx audits will absolutely love you if you tell them developers and database developers do not work with anything related to "actual live and/or production data."

The Data Generator is part of a suite of functions which allows you to copy the schema of an existing database to your desktop, populate it, and test it - along with any changes you or others deem good and worthy. Part of this testing requires data. But using production data - including actual credit card numbers (even if they are encrypted) and other personal information - exposes that data to environments less-controlled than the production environment. Use the Data Generators to populate your local copy of the database with random unicode strings, or random data from pre-defined selections (you have to see this to believe it).

"How does a bunch of unrelated gibberish allow me to adequately test my database, Andy?" Again, I'm glad you asked. It's not unrelated! The Data Generators populate the database preserving referential and relational integrity. This sure beats those data scramblers I wrote back in the day. Again, hats off to the Microsoft developer team!

:{> Andy

Technorati Tags: Team Edition Database Professionals Team System SQL Server Test-Driven Development 

posted Saturday, June 10, 2006 12:39 AM by admin with 1 Comments

Preparing for the Reston Code Camp!

I'm pretty psyched about heading to Reston tomorrow for the Reston Code Camp!

I get to meet some really cool people. And I'm looking forward to sitting in on a few sessions and learning some cool stuff! I'll have a few copies of on hand for swag.

This is also the weekend we begin moving into our new house - another thing to be psyched about!

If you read this blog and attend the Reston Code Camp tomorrow, please introduce yourself. Hope to see you there!

:{> Andy

Technorati Tags: Reston, Va Code Camp Developer Community SSIS

posted Friday, June 09, 2006 2:22 PM by admin with 0 Comments

June 8 2006 - SSIS Tips and Tricks Presentation

Last night's SSIS Tips and Tricks presentation to the Richmond SQL Server Users Group was lots of fun!

I tried a couple things different: First, it was nearly all code. I had one slide at the beginning of the presentation and then just dove into code for the rest of the evening. Second, I used Camtasia Studio to record segments of the presentation.

The first recording on SSIS Constraints is available online. and let me know what you think!

:{> Andy

Technorati Tags: Developer Community SQL Server Richmond, Va SSUG SSIS Constraints Camtasia

posted Friday, June 09, 2006 10:24 AM by admin with 0 Comments

Visual Studio Team Edition for Database Developers!

Microsoft just announced , a new addition to the Visual Studio Team System family!

I'm excited about this! There are lots of cool features for database developers to be happy about, but the most exciting screenshot I saw dealt with database testing:

This just rocks! I can't wait to download this and put it into practice. The bits ship 11 June 2006, according to .

:{> Andy

Technorati Tags: Team Edition for Database Developers SQL Server Team System Visual Studio Test-Driven Database Development TDDD

posted Friday, June 02, 2006 12:10 AM by admin with 0 Comments

Phil Factor's SQL Sudoku Generator

Phil Factor demonstrates some snappy SQL programming with his Sudoku Generator - check it out!

:{> Andy

Technorati Tags: SQL Server Sudoku Phil Factor Developer Community

Speaking Engagements: June 2006

In June, I'm speaking at the following locations / dates:

1 June 2006 - "Scrum with Visual Studio Team System" to the Richmond .Net Users Group.
8 June 2006 - "SSIS Tips and Tricks" to the Richmond SQL Server Users Group.
10 June 2006 - "Beginning SSIS Development", "SSIS Development with Team System", and a chalk talk on "Agile Database Development Practices" to the Reston, VA Code Camp.
27 June 2006 - "Scrum with Visual Studio Team System" to the Capital Area .NET Users Group.

If you read my blog and attend one of these events, please introduce yourself and let me know!

:{> Andy

Technorati Tags: Developer Community Code Camp Speaking SSIS SQL Server Team System Team Foundation Server

posted Saturday, May 20, 2006 11:01 PM by admin with 1 Comments

SQL Server Management Studio (SSMS) and Team System Source Control - the MSSCCI Provider

Source Control is important. To quote a former professor, "There are two types of developers: those who backup their work, and those who will." Team System provides integrated access to the Team Foundation Server Source Control engine for Visual Studio 2005 users.

Q: But what about those who use other Microsoft development platforms?
A: Microsoft Source Code Control Interface (MSSCCI).

The current version of the MSSCCI Provider allows applications that do not integrate with Team Explorer to utilize TFS Version Control. In addition to SQL Server Management Studio (SSMS), supported applications include Visual Studio .NET 2003, Visual C++ 6 SP6, Visual Visual Basic 6 SP6, Visual FoxPro 9 SP1, Microsoft Access 2003 SP2, and SQL Server Management Studio. Previous versions provide integrated TFS source control for a variety of development platforms - including Visual Studio 6.0 applications.

To use SSMS with TFS Source Control, you need to download and install the current version of the .

If I open SSMS and click Tools, Options prior to installing the MSSCCI Provider,

I have no options for Source Control:

Install the MSSCCI Provider by double-clicking the file or right-clicking it and selecting Install:

The wizard starts - click Next to continue:

Accept the license agreement and click Next:

Select an installation folder, execute permissions, and click Next:

Click Next to confirm installation:

When installation completes, click Close:

When complete, I have to close and re-open SSMS to access TFS Version Control functionality:

 

:{> Andy

Technorati Tags: SQL Server Team System Source Control TFS Visual Studio SSMS Management Studio

 

Configure Reporting Services to consume SSIS packages

A really cool feature of SQL Server 2005 is the ability to use a SQL Server Integration Services (SSIS) package as the source for a SQL Server Reporting Services (SSRS) report. There's an example in chapter 17 of the Wrox book .

Before you can take advantage of this functionality, you have to make a couple changes to some SQL Server config files.

Note: SSRS and SSIS must be installed on the same server to utilize this functionality.

Important Note: There are security implications to consider. Please see  for more information.

Navigate to C:\Program Files\Microsoft Visual Studio 8\Common7\IDE\PrivateAssemblies (assuming you installed SQL Server on the C: drive) in Windows Explorer. Open the RSReportDesigner.config file in a text editor:

You can use any text editor - or even the Visual Studio 2005 IDE. Call me old-fashioned, I like Notepad. :)

Remove the comments from the config sections (there are two) beginning with the phrase: :

Don't forget the End Comment markup ("-->") at the end of each commented line. 
Save the file and close Notepad.

Next, navigate to C:\Program Files\Microsoft SQL Server\MSSQL.n\Reporting Services\ReportServer and open the rsreportserver.config file:

Note: On my demo machine, the file is located in ...\MSSQL.3\.... This will vary depending upon the number and type of SQL Server 2005 family of products you have installed on your machine.

Again, uncomment the section beginning with the phrase: :

 Save the file and close it.

Now, when you create an SSRS data source, you have the option of using SSIS as the data source:

How does this work? When your report refreshes, Reporting Services will call and execute the SSIS package. An important security consideration is the SSRS service account provides the security context for the SSIS package. For this reason, it is a good idea to hard-code SSIS connection string security data - you do not want to give the SSRS account the same permissions as you give an SSIS package.

:{> Andy

Technorati Tags: SQL Server 2005 SSIS SSRS Reporting Services Integration Services Data Source

 

posted Saturday, May 20, 2006 3:46 PM by admin with 0 Comments

Announcing the Richmond SQL Server Users Group!

Frank La Vigne and I are proud to announce the formation of the Richmond SQL Server Users Group!

The first meeting is scheduled for 6:30 PM 11 May 2006 at 4600 Cox Road, Glen Allen, VA. I'll be speaking, and since this is the first meeting I think I will start at the beginning - with a presentation on installing and configuring SQL Server 2005.

We're working on a website and hope to have it online sometime this month.

Special thanks to Fahrenheit Technology for sponsoring our inaugural meeting!

I hope to see you there Thursday!

:{> Andy

Technorati Tags: SSIS Sql Server Developer Community Richmond Virginia

posted Sunday, May 07, 2006 1:58 AM by admin with 0 Comments

SQL Server 2005 SP1 Installation Issues, Part 2

As described in Part 1, I ran into a couple issues installing SQL Server 2005 SP1.

The second issue took the form of a "The following files are currently locked" error in a "Locked Files Found" dialog:

To correct this issue I followed this procedure.

1. Open Services and stop the "SQL Server FullText Search" service (right-click the service and then click Stop):

2. Stop the "SQL Server Integration Services" service in similar fashion:

3. After about 20 minutes of processing, the service pack installation completed successfully.

4. I had to reboot the server to get the SQL Server Integration Services service to start again.

:{> Andy

Technorati Tags: SSIS Sql Server SP1 Developer Community Richmond Virginia

SQL Server 2005 SP1 Installation Issues, Part 1

I ran into a handful of issues applying SQL Server 2005 SP1 to my Development SQL Server.

The first issue was an "Unable to install Windows Installer MSP file" error:

After some searching, I found  that helped with this error. Here are the steps I took to address it with screenshots.

1. Open RegEdit and navigate to the HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Microsoft SQL Server\90\Bootstrap\MSIRefCount key:

2. Select the MSIRefCount key. Click File, then Export:

3. Select a Path and Filename to store the contents of this key and click the Save button:

4. On the SQL Server 2005 installation media, locate the SQLSupport.msi file. RIght-click the file and click Uninstall:

NOTE: There is no indication the uninstallation succeeds. You may or may not see a brief dialog with a progress bar, but there is no status message at the end of the uninstall.

5. Re-install the SQLSupport.msi file by again right-clicking the file. This time, click Install to install the file:

6. Return to RegEdit. Click File, then Import:

7. Navigate to the file you exported earlier:

8. Click Open. If successful, a dialog will display status:

This got me over the first hurdle, but I hit another... more in Part 2.

:{> Andy

Technorati Tags: SSIS Sql Server SP1 Developer Community Richmond Virginia

 

posted Wednesday, April 26, 2006 11:28 PM by admin with 3 Comments

Last Minute Fill-In Speaking Gig

I had an opportunity to speak to the Richmond .Net Users Group last night as a last-minute fill-in guest speaker.

The folks in attendance were simply awesome! It was an honor (as always) to be able to present to a cool group of folks. Frank LaVigne, MVP (congratulations Frank on being awarded the 21st Tablet PC MVP on the planet!) and I had concerns about presenting a database-centric topic to a developer group. But it went very well. It turns out there are a lot of developers delving into SQL Server 2005 - either by choice or necessity.

"Hey you!
Do you know how to spell SQL?
Good.
You're our new database resource."


You laugh... this is a paraphrase of the discussion that converted Andy from a web developer to a SQL Server DBA...

I'm working on more Team System presentations for upcoming events, like the Richmond Code Camp. I will be presenting "SSIS with Team System" there and at upcoming user group engagements.

Plus, Frank and I are (re-) starting the Richmond SQL Server Users Group. The first meeting is planned for May 11, 2006 and we plan to hold monthly meetings the 2nd Thursday of each month. More details will follow...

:{> Andy

posted Friday, April 07, 2006 9:36 PM by admin with 0 Comments

Interface Not Registered / Class Not Registered Error in SSIS

I ran into a couple errors recently when trying to create new SQL Server Integration Services (SSIS) projects. One error stated:

Failed to save package file "C:\Documents and Settings\Administrator\Local Settings\Temp\1\tmp2B.tmp" with error 0x80040155 "Interface not registered".

The other stated:

Failed to save package file "C:\Documents and Settings\Administrator\Local Settings\Temp\1\tmp2B.tmp" with error 0x80040154 "Class not registered".

These errors were encountered on a new laptop and a new virtual PC. Both had Visual Studio 2005 installed, so I suspected some sort of conflict. On the VPC, I loaded VS 2005 first, followed by SQL Server 2005 Developer. I noticed the client tools didn't install, although I thought I'd checked that box. To correct, I executed the setup for client tools. When completed, my client tools were available and creating an SSIS project succeeded.

But the laptop wasn't so simple. I thought "I have a solution!" and went about re-installing the client tools, but it didn't correct the issue!

So I popped on Google and searched for similar issues. I found a helpful post at MSDN Forums: . Executing two RegSvr32 commands did the trick:

regsvr32 msxml3.dll
regsvr32 msxml6.dll 

When all else fails, read the instructions!

:{> Andy

posted Thursday, March 30, 2006 6:36 PM by admin with 0 Comments

April Speaking Engagements

My "Buy The Book 2006" tour rolls on! :)

In April, I will be speaking at the following locations:

  • 12 Apr 2006 - Triangle .Net User Group
  • 20 Apr 2006 - Roanoke Valley SQL Server Users Group
  • 22 Apr 2006 - Richmond MSDN Code Camp!

If you're going to be in the area one of those dates, please stop by and introduce yourself as someone who reads this blog!

:{> Andy

posted Thursday, March 30, 2006 6:36 PM by admin with 0 Comments

NoVa SQL Server Users Group

I was honored to present a session on Beginning SSIS Development at the NoVa (Northern Virginia) SQL Server Users Group last night. I met some great people and learned a lot.

I can hear you thinking "What? You learned a lot?" Absolutely! I always learn when presenting. In fact, I would argue presenting / teaching is the best way to learn.

Presenting forces me to remain knowledgeable in my field. And it provides immediate feedback about my success at ths endeavor.

Any new technology - especially one as flexible and powerful as SSIS - will be used in unanticipated ways. This will generate unexpected results, which will in turn generate perplexing questions to presenters - usually in front of a large crowd! :)

It is all good.

It's called "learning." Experience has taught me learning is best done in groups. No one can master it all and not all at once. This is why teaching teaches.

Thanks, Nova SSUG, for the opportunity and knowledge shared!

:{> Andy

Open SQL Server Management Studio (SSMS) quicker

Almost every weekday morning I read Steve Jones' thoughts published in the SQLServerCentral newsletter editorial section. Today (24 Mar 2006) he mentioned SQL Server Management Studio loads and opens slowly. I agree with Steve - I hate waiting for software to load.

As a developer, I know it's a trade-off between "at my fingertips" functionality and having to wait for everything to load as I click on it, and I think making me wait once at the beginning is the right choice - but it doesn't help... I still hate waiting.

I found a couple of changes that helped me. I'm sure there are more and I encourage you to add your tips and tricks as comments.

First, I open the Registered Servers view (View, Registered Servers):

Next, I register some servers (right-click Database Engine in Registered Servers view, click New, then click Server Registration):

Next, open SSMS Options (Tools, Options):

Finally, I set the environment to "Open empty environment":

Click OK to accept the changes.

This shaves some time off opening the SSMS environment. Again, please add your tips and tricks!

:{> Andy

Technorati Tags: Sql Server 2005 Sql Server SSMS Management Studio

What should be on an IT resume?

The purpose of a resume is to get an interview - period.

So what should your resume contain? Experience leaps to mind. Education looks good also. What about an abstract? or job objective? or even your "perfect" or "dream" job?

Many experts say all this and more.

My limited experience searching for qualified DBAs has lead me to believe the search for candidates is either feast or famine. Either you cannot find anyone - qualified or not - or you're deluged with qualified resumes.

So what do I look for in a resume?

First, an indication of experience. Experience is probably the most important thing for DBA work. Second, I look for... ok, all I look for is experience on the resume. If I see some, I'll schedule a phone interview.

:{> Andy

posted Tuesday, March 07, 2006 6:29 PM by admin with 0 Comments

Announcing the Roanoke Valley SQL Server Users Group!

It's a cool time to be working in IT! I know good things are happening all over, but it's good to see groups and events going strong around Virginia! :)

Some technologists in the Roanoke area are starting a new SQL Server Users Group: the Roanoke Valley SQL Server Users Group. Harold Buckner and Robin Edwards are a couple of good people I've spoken with regarding this effort.

Founding a new User Group is hard work. A meeting location has to be located and usually prepared - and then cleaned after the meeting. You have to identify speakers and presenters willing to travel to your location, then schedule them and any resources they may require (LCD projector, etc.). Organizers have to then get the word out. I'm telling you, it's a lot of work!

I think Harold, Robin, and their associates are off to a great start - they had about 30 people attend their kickoff meeting last month! Go guys, go!

For more information about RVSSUG, visit http://www.rvssug.org/ or contact Harold Buckner at:

:{> Andy

posted Friday, March 03, 2006 6:28 PM by admin with 0 Comments

SOx

I received an advertisement brochure recently. Prominently displayed on a front page was section was this eye-catching question: "Is compliance taking over your life?"

I responded (out loud, even): "Not anymore."

It occurred to me how less stressed my professional life is now that I am working for a private firm. The stress from my former Fortune 500 corporate experience was due in large part to Sarbanes-Oxley compliance - or rather the interpretation of Sarbanes-Oxley compliance.

Whether you agree with the legislation or not, most admit there was clearly a need to do something in response to the WorldCom and Enron scandals. So, something was done. Personally, I believe the legislation attacks the wrong side of the equation for this reason: there were already laws on the books to address the crimes committed at these corporations. If Congress truly wants to protect investors, educate them. And if Congress simply must pass a new law, pass legislation requiring investors become certified before being allowed to invest in publicly traded companies. (Step 1: A DVD of me pointing at the camera, screaming "YOU CAN LOSE ALL YOUR MONEY IF YOU PUT IT IN THE STOCK MARKET... ALL OF IT!!! DO YOU UNDERSTAND?!?" Step 2: Sign the document acknowledging you understand what you learned at Andy's School of Investing.)

But I digress...

While I was enduring the stresses placed upon a sole database administrator group manager by internal auditors, a colleague mused: "Those can, do. Those who cannot, teach. And those who cannot do or teach, audit." That was mean (...apologies to all my auditing readers out there...), but I think I understand the underlying sentiment.

Given the tools on hand, we were faced with unpleasant choices:

  1. Cease supporting business operations. It was simply not possible to comply and execute DBA tasks required to keep the business running. Without naming industries, companies, or names, ceasing support would have meant hardship to thousands of people already enduring enough hardship and economic loss to literally thousands of others.
  2. Refuse to comply. Which would have solved several stressful issues but created a few more - such as how to pay the bills, eat, etc.
  3. Lie. I could break my personal code of ethics and possibly the law of the land, and misrepresent the facts of the matter.
  4. Be honest. And take the ensuing whoopin'.

I chose to be honest. My reward was pressure from every imaginable angle.

From business, sales, and accounting, "Why can't you just comply and end all this?"

From auditors, "We will have to report this to _____. They will open an incident. It will be filed with the SEC. It will be made public."

From executives, "Make this go away."

It was ugly. And it all stems from an open season on business data. Heck, the auditors at my former employer were reaching into the personal development databases of developer workstations. I understand some of it, but not all.

I'm interested in your thoughts on the matter. Have any of you had similar experiences with SOx compliance?

:{> Andy

posted Wednesday, January 18, 2006 6:22 PM by admin with 3 Comments

Echoing some thanks

In his excellent blog, my friend and co-author Haidong Ji thanks Andy, Brian, and Steve for SQLServerCentral.com. I second the sentiment! We, the SQL Server community, are indeed fortunate to count them among us. The innovation and vision offered by Andy, Brian, and Steve (listed in alphabetical order here...) in creating and maintaining the SQLServerCentral community often goes unnoticed - which is itself a testament to their hard work and diligence.

In short, thanks guys!

:{> Andy

posted Tuesday, January 17, 2006 6:21 PM by admin with 0 Comments

February speaking engagements

I will be delivering a Beginning SSIS Development presentation at the Baltimore SQL Server User Group meeting 1 Feb 2006, and at the Hampton Roads SQL Server User Group 16 Feb 2006.

Beginning SSIS Development covers:
 - Introduction to the new SSIS Integrated Development Environment
 - Control Flow and Data Flow discussion
 - An overview of controls, connections, and package flow
 - Troubleshooting techniques
 - A demonstration (or two, depending on time)
 
Details and directions are available at the respective websites. They should be fun evenings - I always enjoy presentations! If you're in the area and read this blog, stop by and introduce yourself!
 
:{> Andy
posted Wednesday, January 11, 2006 6:20 PM by admin with 0 Comments

Production Virtual Servers?

I recently documented building a virtual server for use with the Team Foundation Server Dec 2005 CTP. It was a lot of fun / work - and it's documented at VSTeamSystemCentral.com.

An opportunity at work prompted use of another virtual server to facilitate a data-transformation-intense software migration. In order to make this particular migration work, I needed to install an old ODBC driver. I did not have access to the driver installation - apart from installing a suite of software products purchased back in the day. I needed to land the migrated data on an existing test server and I did not want to corrupt other software currently installed there.

So... I built a VPC, installed Windows and SQL Server 2k. I loaded the legacy software package, which installed the driver, then built some DTS packages to migrate the data from the source to my target server. Voila!

It's worked wonderfully. Among the many benefits is the low impact to our existing Development / Test environment.

This experience - coupled with clustering functionality built into Virtual Server 2005 R2 - has me seriously considering Production Virtual Servers. Thoughts?

:{> Andy

Gatekeeper or Roadblock?

Which are you? Gatekeeper or roadblock? ... or none of the above?

When it comes to database work, both stop "things" from occurring. Here's a couple/three questions I ask myself when my knee begins its pre-jerk twitch:

1. Are we in the data-protection business? Does this business in general - and my job specifically - exist solely to guard this data from everyone? I am still quoted at a manufacturing facility. I once said to a network engineer: "I understand, we're a network company. Apologies if all these ____-making efforts are getting in your way." (... for some reason, I no longer work in manufacturing...)

2. Does this request support or provide business value? Not: Is it a duplication of data? or even: Does it violate 3rd normal form?

3. Perhaps the most important question when I truly disagree with the request (which is rare, mind you): Is this battle worth fighting?

I consider myself a little of both gatekeeper and roadblock, at times. Mostly, I see my DBA role in the IT department as facilitator. When someone shows up with a request, I endeavor to help them succeed.

How about you?

:{> Andy

posted Friday, January 06, 2006 6:16 PM by admin with 4 Comments

How to build a Team Foundation Virtual Server (TFS)

As promised, you can learn more about my Team Foundation Server setup experience at VSTeamSystemCentral.com.

I have started posting a series of articles (Team Foundation Virtual Server) describing the process I used to build and configure a virtual PC similar to the VPC Microsoft distributed with their releases of Visual Studio 2005. At the time of this writing, 6 of 12 to 15 articles have been posted. I attempted to capture screenshots for every step I used to build a functional TFS server.

I do not provide software. The series assumes you have access to an MSDN subscription or licensed copies of Windows 2003 Server Enterprise, SQL Server 2005 Developer, Visual Studio 2005 Team System (or the trial version), and Microsoft Virtual PC 2004 SP1.

Registration is required to access the content.

:{> Andy

posted Thursday, December 22, 2005 6:12 PM by admin with 0 Comments

Team Foundation Server - Dec CTP

I just finished installing the Dec CTP of TFS.

I haven't tested the installation yet (that's the task du jour), but I am quite impressed with the installation. Concise instructions, well-written and well-formatted help. And (for me at least), no ugly and unexpected dialogs.

I installed on a VPC running Windows 2003 Server enterprise configured as a standalone AD / DNS server on its own local domain. My only issue was with SQL Server Surface Area configuration: I needed to expose TCP for communications. The pre-installation checks caught this and warned me before the TFS installation even started - which was really nice.

All in all, installation of the Dec CTP was a positive experience. Now, on to testing...

 

:{> Andy

SQL Server 2005 and Team System

For arguably the first time ever, DBAs have a stable Microsoft development environment with integrated source control.

There's a chapter in the upcoming Wrox Press book "" on this very topic. It serves as an introduction to some source control and project management features available to DBAs using SQL Server 2005.

There's lots more information available online about Team System - I find most of my information on blogs:

There is also a Wrox Press book due out in February entitled "".

"Why should we care about Visual Studio, Andy?" I'm glad you asked. If you haven't yet tinkered with the new SQL Server 2005 development environments, you may not know this: When you develop SQL Server applications in SQL Server 2005, one of the tools available to you is the Visual Studio 2005 environment. In fact, if you develop business intelligence applications (Analysis Services, Integration Services, etc.), you utilize a tool called the SQL Server Business Intelligence Development Studio (BIDS), which is a version of Visual Studio with tools for developing SQL Server business intelligence applications.

If Visual Studio is a new environment for you, learning about it will make you a more effective DBA when you move to SQL Server 2005.

If you don't use a source control product currently - or even if you do - I encourage you to examine the new version of Visual SourceSafe (2005) and Team System.

:{> Andy

Want to Double Your Salary?

Catchy title, eh? :)

Salaries are one side of a trade. A salary is presented to you on a semi-regular basis from a business venture or organization. Most of us consider salary when choosing with which business venture or organization we should spend our time and effort - because time and effort are what we bring to the table.

The other side of the trade is what you bring to the organization. What do you do with your time and effort that helps the company achieve its goals and objectives? The key concept here is business value. (Apologies... the image of the banner from the movie Office Space proclaiming "Is this good for the company?" keeps popping into my head...)

The balance between these two forces of business physics - business value and your time and effort - determines your salary. (Perhaps that's naive. It's more accurate to say your understanding of these forces of business physics determines your salary. Increasing your understanding is the purpose of this post.)

Although you may learn nifty things at work and enjoy learning, businesses are not training centers. If you want to learn new, cool, and exciting things, there are places for that sort of thing - they're called "schools." If it's recognition you seek, try a book or speaking at seminars - or even starting your own website.

This may come as a shock, but businesses exist for the sole Gordon-Gecko-esque, Ebeneezer-Scrooge-ish purpose of making money. Work is a place to get things done - to accomplish things that bring business value - which in turn increase and/or sustain the amount of money flowing into the business. "Is there business value in learning and recognition?" Absolutely! Businesses wouldn't waste resources on these activities without a return on the investment.

"So, Andy, I'm confused... are you saying businesses should or should not engage in training and recognition?" I'm not talking about whether business should or should not do anything. Rather, I am attempting to explain some harsh realities regarding life in the business jungle. The brutal fact is: Businesses engage in these types of (expenses) activities as a means to an end - and that end is not solely to make you feel better about yourself. The reality of the goal is something closer to: "If you feel better about yourself and your job, you are more likely to produce more business value with your time and effort." It's not as much about the what as it is the why.

The software Business should be considered as it is addressed here - software with a lower-case "s;" Business with a capital "B." It is a Business first. Please keep that in mind.

The software Business has matured to adolescence at best. This presents a set of issues unique - but surprisingly predictable - to adolescent industries. Other industries have matured in the past. They offer models of the phases (into which I will not delve here) through which all industries grow. The current, adolescent state of the software industry is somewhat analagous to the American West - just about the time some semblance of law and order arrived on the scene - or the early years following the industrial revolution. My mother (who raised four "rambunctious" sons to adulthood - no small feat for any woman) would describe it as "scrappy."

"So, Andy, how do I double my salary?" you ask? "Quadruple your value - and split the difference."

"Lovely advice. How does one accomplish this?"

"I'm glad you asked."

You can be a good DBA. You can be a good coder. You can be nice. You can be fun. You can practice good hygiene (I hope you do, in fact!). You can get to work early and stay late. All well and good - but what have you done for the business lately?

Again, brutal.

Again, true.

We, as technology professionals, get paid to think. So how do we think better? One method is more familiar to technology professionals than others (but there are many ways to "think better" <-- loaded term, by the way...): Think about scale.

Enterprise technologists deal with scale daily. It's something we're uniquely qualified to comprehend. We usually learn about it as we watch the best laid plans of mice and men go awry right before our deploying or disaster-recovering eyes.

Does "scale" scale? Why, yes it does. It scales right out of our little (lower-case "s" software) world and into the (capital "B") Business world rather nicely. In fact, some business theory relies heavily on concepts of scale in organizations. At the very least, we should be among the first to identify a scaling business issue.

"Specifics, Andy - give me specifics!"

Ok.

How do you know your enterprise application has reached the limit? What are the symptoms of it maximizing its potential? hitting the wall? dashing itself to pieces against the rocky coast of your competition? For one, the "old way" - the way that has worked so well for so long - stops working. Processes bog, traffic slows, complaints mount, crises loom. Have you ever seen this in software? Have you never seen this in Business?

Your response requires strategy. Business Strategy For Geeks is a topic for another post. But simply recognizing - and effectively communicating - issues of scale will add to your business value. And it's really as simple as applying skills you already possess in a different field.

There is opportunity for you to improve your business value to your current orgainzation. As such, there is also opportunity to increase your current salary. It is a trade, after all.

:{> Andy

posted Thursday, October 06, 2005 6:02 PM by admin with 0 Comments

On Book Authoring (for the first time), part 2

In an earlier post, I shared some revelations I experienced as I participated in authoring a couple chapters for an upcoming SQL Server 2005 Integration Services book. I feel inclined to share some more, so here goes:

1. It's a lot of work. I've heard that from authors before, and I suppose it just didn't take. An experienced author and very good friend shared that he wouldn't wish writing on his worst enemy. I understand the sentiment and the editing has just started - I'm certain there's more to come.

2. It's a once-in-a-decade (-perhaps-lifetime) honor and opportunity. I've been reading books published by this publishing label for a decade. I always admired the style and content of their books. Some were better than others but all in all, they publish cool stuff. To have an opportunity to write for them is humbling and amazing all at the same time.

On balance, the work is well worth the honor and opportunity.

:{> Andy

posted Monday, August 08, 2005 5:57 PM by admin with 0 Comments

Which "flavor" DBA are you?

   I received a cool compliment today from a peer who's a developer. He said, "You know, I really like having a DBA on my team!" I have to tell you, it made my whole day!

   It led to a discussion about past experiences and expectations, and I shared something I thought was pretty much common knowledge: there are three types of DBAs. My peer was shocked, so maybe the knowledge isn't so common after all.

   The three "flavors" of DBAs I define are:

  1. System, Operations, or Production Support DBAs - these DBAs write maintenance plans in notepad and have no qualms whatsoever about executing in command-line. They were DBAs in the old days, when we carved our own ICs out of wood. They will get your server and database back online fast - and with less data corruption than anyone else on the planet. They live for torn pages and I/O faults.
  2. Application Support DBAs - these DBAs are familiar with one or more (usually complex) applications. I'm talking PeopleSoft, Seibel, and SAP here. If you want to customize a screen or write a one-off web application, you desperately need these folks.
  3. Database Developers - these DBAs are ruthless bit-heads. They use bigint and byte fields for masking binary states. They can optimize a stored procedure in their sleep and wrap an API around a database so developers never have to consider writing SQL that directly hits tables. They are performance freaks that will work 18-hour days on weekends to test in Production - when it's "safe."

   Do you think DBAs fall into these categories? Do you know any that do? Do you see yourself in there anywhere? Do you have more or less or different "flavors" for classifying DBAs? 

:{> Andy

Technorati Tags: Sql Server DBA flavor

Are you happy with your job?

I am elated with my job. I'm a geek who enjoys business stuff, and I'm employed as a DBA manager.

Are you happy with your job?

The good folks at AGreatResume.com posted an interesting blurb about job satisfaction survey results by career. They collect this data each quarter and publish interesting trends.

:{> Andy

Jax Code Camp!

I'll be speaking at the Jacksonville Code Camp (Jacksonville, FL, USA)!

Sign up at .

Come on out!

:{> Andy

posted Thursday, July 14, 2005 5:40 PM by admin with 0 Comments

blAndySql

:)

A little Hungarian (or pseudo-Hungarian) notation is a nice touch to get us started, I think...

...and this blog will contain things I think about, questions I have, and thoughts about answers to these and other questions. It will also contain numerous typos (as I have not yet discovered the spell-checker) and the occasional double entendre - and maybe, just maybe, some humor.

Your responses are encouraged! Initially (at least), I am not moderating user comments. I do this for two reasons: 1) I like free speech and I'm prepared to deal with the consequences for now; and 2) If someone is so upset as to rant about something I have written, this is probably as good a place as any for them to do so.

Ok.

Let's start with the history of Andy Leonard, part 1. I was born... wait, not that far back - we'll just skip to the technical highlights. :)

I learned Motorola 6800 machine code the summer I turned 12. That was a few years ago - back when we used to carve our own ICs out of wood. By the end of that year, I was coding in BASIC.

As a hobbyist programmer, I endured years of derision from professionals and peers for "not learning a real programming language." The simple truth was and remains: I've always liked BASIC.

I learned Visual Basic as VB 2.0 was being released and have stayed with the language as it moved into the realms of 32-bit development, classes, and native compilation.

At the time of this writing, I use VB.NET 2003 and 2005 beta for development work and play. Why? I still like it... probably for the same reasons I like chocolate ice cream.

I - like many of you - became a DBA completely by accident. Until very recently, I would not even refer to myself as a DBA (... my opening line at the first interview for my current DBA job: "I don't consider myself a DBA." I'm not kidding.). The first clue that I may, in fact, be a DBA came at the 2004 PASS Summit in Orlando. I told people my job was to tune a 1.6 TB SQL Server 2000 data warehouse so 90 users could write ad hoc queries and then witnessed aghast expressions on the faces of folks whose names I had been reading on TechNet for years.

I can - and likely will - share more about the methodology employed to tune the aforementioned data warehouse in this blog. The secrets to my success lie in my engineering background... digressing a bit:

Programming was a hobby until the 1990's. My trade at that time was electronics technology, which still brings immense enjoyment when I have the time to breadboard. I was lured into manufacturing by the opportunity for more challenges (money) and found a new home in industrial automation. It was here that my hobby became a profession.

After a few years in industrial automation, I decided to strike out on my own. I wrote one of the first completely web-based manufacturing execution systems (MES) and formed a business to market it. Things went well with the business for about five of the six years it was active. Suffice it to say that a general decline in the manufacturing economy created less opportunity for more challenges.

I re-entered the workforce as the tech bubble was collapsing, so it made sense to get certified. The MCSD got me enough second interviews to justify the expense. Plus, heck, I like having letters after my name.

I was born in Virginia but now live and work in Jacksonville, FL. The weather's nicer here - plus I'm a beach person. The coolest part about living in Florida (besides the hurricanes) is calling my brothers back home during the Fall and Spring and asking about the weather up there. They hate me. And since they're all bigger than me I can never return.

So, that's my opening post. Comments? Questions? Bring 'em on!

:{> Andy

posted Wednesday, June 29, 2005 5:46 PM by admin with 0 Comments