Writing clean code in SSIS: formatting

2015-04-02

It has been suggested that consistently formatted code has a lower defect density (bugs per lines of code). Though SSIS is a visual designer, I hardly think this excludes it from consideration. I have no empirical evidence, but anecdotally, I can say I have typically found more problems with messy packages than well groomed ones.

So why is it so few developers bother to format their packages?  Well, for one, SSIS does not auto format code the same way that modern IDEs do, or Visio for that matter. It's extra work to do the formatting, even with the format feature in the tool (which often has unexpected results). Devs must not think it matters too much or perhaps they just have a really bad eye for neatness. 

So here are a few rules to live by while developing in SSIS:


Will these simple rules reduce defects in your code?  Maybe.  It will at least demonstrate pride in your work and show that you care what the next person is walking into when they inherit it.  And you will thank yourself when this becomes an obsessive habit.  

Mark Wojciechowicz

Labels: