﻿<?xml version='1.0' encoding='UTF-8'?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/"><channel><title>SQLServerCentral / Editorials / SQLServerCentral.com  / Document First, Code Later / Latest Posts</title><generator>InstantForum.NET v2.9.0</generator><description>SQLServerCentral</description><link>http://www.sqlservercentral.com/Forums/</link><webMaster>notifications@sqlservercentral.com</webMaster><lastBuildDate>Wed, 19 Jun 2013 22:40:33 GMT</lastBuildDate><ttl>20</ttl><item><title>RE: Document First, Code Later</title><link>http://www.sqlservercentral.com/Forums/Topic1356343-263-1.aspx</link><description>As well as helping others who have to maintain your work, documenting something is a great way of crystallizing and 'unit-testing' your own understanding of the process you are going to automate. I don't much care whether anyone ever reads my documentation: Once it is  written, it has already proven its worth in avoiding all those mistakes. If anyone reads it, it is an unexpected bonus. As I said in the editorial, a good user-documentation is great for tying down the estimates of development time. For any professional developer, being able to say accurately how long a job will take is a way to a long and successful career. In the days when applications were expected to have proper documentation, Microsoft produced a TSQL programming manual for SQL Server (I think it was version 6) It was wonderful, brief, simple, but comprehensive; and I remember marveling at its clarity. I read it over and over again, marveling at how little I remembered of the last reading,  until a colleague stole it. Come to think of it, he might have merely been reclaiming his property, but I resented it when I lost it.</description><pubDate>Tue, 11 Sep 2012 10:55:55 GMT</pubDate><dc:creator>Phil Factor</dc:creator></item><item><title>RE: Document First, Code Later</title><link>http://www.sqlservercentral.com/Forums/Topic1356343-263-1.aspx</link><description>Hm.  I certainly try to document as much of my coding as I can manage at my current workplace, but I could certainly understand the feelings of futility some people have in regards to the matter :-).  Wrote up a new method to calculate shipping rates awhile back, and recently added some more error-checking functionality to it.  The error-check form has handy bits written on it about what errors would usually show up, and how to handle them, which would usually take less than 15 seconds to fix.  I came in yesterday morning to the owner saying there was an error with the rate calculator, and could I please handle it.  It was the very first error documented on the form, which just required a deletion from that same form :crazy:Still, documentation's definitely a wonderful thing; I fully understand the need to do so, either before or after a project (ideally beforehand, but that can be a bit too idealistic).  The point's driven home all the more when I look at vendor coding that doesn't have documentation, or the documentation is from several versions ago and doesn't cover new core operations.  Quite painful!</description><pubDate>Tue, 11 Sep 2012 10:11:37 GMT</pubDate><dc:creator>hisakimatama</dc:creator></item><item><title>RE: Document First, Code Later</title><link>http://www.sqlservercentral.com/Forums/Topic1356343-263-1.aspx</link><description>[quote][b]Evil Kraig F (9/10/2012)[/b][hr]I agree with the theory.  The practice, on the other hand, is a lot harder to implement."Can you slap me together a quick prototype?  I need to see data in this for it to make sense to me if it's right"... said prototype heads to production a week later."Hey, I need a quick page that'll let me access customer data in this way.  No, don't worry, it's not a big deal..."...  Said page suddenly becomes the core of the new CRM system... and you're never given a chance to redesign around the 4 minute data pull it takes per page."How do I know if the report looks right?  We don't do widgets and gaskets, I need real numbers."  Said report gets slapped together with faked data.  "Still, this isn't right, look, the numbers don't..." Fine, so you build the entire damned thing.  "Oh, no, we don't need it anymore... it's not blue in background now, it's green.  Cancel the entire report request, thanks, we built it in Excel."  *blinks*A shop cannot be hyper-agile and flexible and run under the 'sign every blessed thing' conditions.  Larger projects I agree should go through this process... but then the business learns to send down everything in small bites to avoid the necessary paperwork and signoff so they can just get their stuff done without getting stuck in 2 weeks of meetings.   They don't want to be there any more than we do.No, I don't have any 'good' answers to the problem.  It's person to person more than tech to issue.  Build me any semi-agile system and people will gravitate towards the one where it's not their *** in a sling if it doesn't work.  Set everything in stone and 'IT is just impossible to work with!'.  Leave it all on the fly and you get a rotting dung-heap.  We'll figure it out eventually, I guess.[/quote]Agreed.  There exists a balance somewhere between "paralysis by analysis" and "have it your way fast food".</description><pubDate>Mon, 10 Sep 2012 19:36:23 GMT</pubDate><dc:creator>Jeff Moden</dc:creator></item><item><title>RE: Document First, Code Later</title><link>http://www.sqlservercentral.com/Forums/Topic1356343-263-1.aspx</link><description>The last end-user documentation I ever read was for SuperCalc. It was a long time ago, but that was how I taught myself about spreadsheets.</description><pubDate>Mon, 10 Sep 2012 16:31:44 GMT</pubDate><dc:creator>phonetictalk</dc:creator></item><item><title>RE: Document First, Code Later</title><link>http://www.sqlservercentral.com/Forums/Topic1356343-263-1.aspx</link><description>I agree with the theory.  The practice, on the other hand, is a lot harder to implement."Can you slap me together a quick prototype?  I need to see data in this for it to make sense to me if it's right"... said prototype heads to production a week later."Hey, I need a quick page that'll let me access customer data in this way.  No, don't worry, it's not a big deal..."...  Said page suddenly becomes the core of the new CRM system... and you're never given a chance to redesign around the 4 minute data pull it takes per page."How do I know if the report looks right?  We don't do widgets and gaskets, I need real numbers."  Said report gets slapped together with faked data.  "Still, this isn't right, look, the numbers don't..." Fine, so you build the entire damned thing.  "Oh, no, we don't need it anymore... it's not blue in background now, it's green.  Cancel the entire report request, thanks, we built it in Excel."  *blinks*A shop cannot be hyper-agile and flexible and run under the 'sign every blessed thing' conditions.  Larger projects I agree should go through this process... but then the business learns to send down everything in small bites to avoid the necessary paperwork and signoff so they can just get their stuff done without getting stuck in 2 weeks of meetings.   They don't want to be there any more than we do.No, I don't have any 'good' answers to the problem.  It's person to person more than tech to issue.  Build me any semi-agile system and people will gravitate towards the one where it's not their *** in a sling if it doesn't work.  Set everything in stone and 'IT is just impossible to work with!'.  Leave it all on the fly and you get a rotting dung-heap.  We'll figure it out eventually, I guess.</description><pubDate>Mon, 10 Sep 2012 12:43:53 GMT</pubDate><dc:creator>Evil Kraig F</dc:creator></item><item><title>RE: Document First, Code Later</title><link>http://www.sqlservercentral.com/Forums/Topic1356343-263-1.aspx</link><description>I've found that documentation before writing a lick of code is actually a pretty easy thing to do.  In the early stages, you don't necessarily have to document HOW you're going to do something.  You only need to document the functional blocks.  It's just like writing comments in code and can be done very quickly.  It's sommethinng I'd do even if it wasnn't required because having a plan of attack is worth its weight in gold when it comes time to either design a database or to write code for its usage.To wit, sometimes all that's needed is a decent flow chart and a bit of narrative to go along with it.  Detail can easily be added as time progresses and doing so is no more difficult than the first blush was.</description><pubDate>Mon, 10 Sep 2012 12:04:35 GMT</pubDate><dc:creator>Jeff Moden</dc:creator></item><item><title>RE: Document First, Code Later</title><link>http://www.sqlservercentral.com/Forums/Topic1356343-263-1.aspx</link><description>It's really about trying to balance the documentation as the needs of the users/process change.  Your team and functional staff need to determine what documentation is absolutely essential and it should be minimal due to the nature of change in the world we live in today.  Documentation is good provided that it is correct, but a working product has more value to your organization.For one conversion project (COBOL to ASP.NET), our  documentation had 6 major revisions (4 before release) and hundreds of minor revisions.  Most of the documentation versions in the earlier phases no longer matches the final product.  There were new compliance requirements, changes in the enterprise systems and payment process.  There was a concrete date that the legacy app would be shut down.  If we didn't hit that target date it would cost us substantially to continue the legacy application and we would have to re-write some sub programs withinCOBOL to meet our requirements. So we had thousands of pages of documents, flows, UML, specs, compiled code, unit tests, etc. that were done over 5 years by various staff/consultants (most gone) that no longer apply to the final product.  We couldn't go fully agile, but we finally convinced the CIO, the functional staff and management to go along that route and we salvaged 1/3 of the code and got the project out in time with less staff.  Was it perfect when we went live?  Nope, but it worked and bugs were triaged quickly.  The second phase which was scheduled for a year was released incrementally in under 4 months.Our source control repository is the documentation.  We have standards for check-ins,tasks, bugs, release cycles and comments in the code to tie back to the source control system.  We can now extract information from the source control system to build any needed documentation AFTER release.  It does require programmers to follow the documentation standards and it isn't perfect by no means, but it works for us.</description><pubDate>Mon, 10 Sep 2012 09:55:27 GMT</pubDate><dc:creator>charles.byrne</dc:creator></item><item><title>RE: Document First, Code Later</title><link>http://www.sqlservercentral.com/Forums/Topic1356343-263-1.aspx</link><description>The customer who doesn't know what they want:[url]http://dilbert.com/strips/comic/2006-01-29/[/url]I'm a "grey beard" and I've run my own shop several times.  I've always insisted on detailed specifications, signed off by the customer, before development work begins (we don't count prototyping as development work).  I had a sales geek grouse once about "how much time it was taking to design the thing, why can't we just [i]do it[/i]?"  When the next project came in, I let him run with it and "just do it."  Afterwards -- after all the carnage, scopus creepus maximus, missed dates, gross budget overruns, etc. -- he came to me and said, "OK, point taken, we should always get specs signed off at the beginning."  Experience has shown me that people who "just do it" are spending more time on a project than if the scope/requirements/sign-off steps are followed.The Business Analyst should always be getting the scope, requirements, and high-level design done before handing it off to the development team.  The developer should be responsible for the details*.  In terms of SQL, I document what [i]kind[/i] of data is to be captured and approximately how much of it is coming in, and the DBA and developer team up to determine the types and sizes...the details.Hopefully everyone has seen the classic "what the customer wanted" drawings (they wanted a tire swing, got a barcalounger hung from steel girders) and it shows how important it is that everyone is on the same page, singing the same hymn, at the same stanza and note.(* - Although one time I was a BA for a hospital system shop and we had a mainframe Y2K project outsourced to India, and they couldn't figure out what had to be done and insisted on a [b]detailed[/b] specification document with the [b]specific[/b] changes we wanted.  I had to, for each of the 140+ CICS and batch COBOL programs, list the row number where the code to be changed was found and show the before and after changes.  I pointed out to the VP of development that if I was going into each program anyway and document the changes, why not have me make the changes and be done with it?  Turns out the CEO "had read a magazine" and wanted an outsourcing firm to do the "menial" tasks and no amount of logic could change his mind.  Needless to say we spent a lot of time and money to get specifications for someone who should never have been allowed near the code in the first place.)</description><pubDate>Mon, 10 Sep 2012 09:15:55 GMT</pubDate><dc:creator>ACinKC</dc:creator></item><item><title>RE: Document First, Code Later</title><link>http://www.sqlservercentral.com/Forums/Topic1356343-263-1.aspx</link><description>[quote][b]bitbucket-25253 (9/8/2012)[/b][hr][quote][b]call.copse (9/8/2012)[/b][hr]I think I have followed a similar trajectory to Phil. I have spent (literally) years writing specifications in the olden days. We spent approximately 40% on the project time on such. Of course by the time things were actually done they diverged wildly from the original - it is certainly true that on any sizable project you will find any number of previously forgotten issues.[/quote]We used the document then code method with:The documentation was reviewed by the user(s), and the last page held a sign off block which simply stated, "I (we) have reviewed this specification on (fill in date and time) and find it to be an accurate statement of the work required and the required results of said work"[quote] on any sizable project you will find any number of previously forgotten issues[/quote] in which case as the items were found the document was updated with the solution of forgotten issues and again an additional sign off block which simply stated, "I (we) have reviewed this specification on (fill in date and time)  and find it to be an accurate statement of the work required and the required results of said work"I find that today's business culture does not properly measure the cost of doing things over and over ... the old idea of measure twice cut once seems to have disappeared.And miracle of miracles the $$$ required are always found to do it over and over and over and over.[/quote]I'm with you pretty much.The problem we always had with getting a 'one true document' was that because we always wrote the addendums as a possiblity to be updated as required, and there were often quite a few, and the actual implementation became slightly divergent when true needs became apparent perhaps even from our side (better way to go) you had to fold in minor changes, potential updates and so forth into one big &amp;#100;ocument. It can work fine of course but the folding in was basically the last priority. I have since those times worked with good PMs who actually do that sort of thing leaving you to get the functionality right - bliss!</description><pubDate>Mon, 10 Sep 2012 03:50:11 GMT</pubDate><dc:creator>call.copse</dc:creator></item><item><title>RE: Document First, Code Later</title><link>http://www.sqlservercentral.com/Forums/Topic1356343-263-1.aspx</link><description>Some how we have to get to a meeting of minds.  I know what I consider documentation and I have consistently said that if I am called up at 3am in a decaffeinated state after nursing a sick toddler the documentation has to be sufficient to resolve a production issue.That said, if the requirements are not written in sufficient detail then how can developers write suitable tests for test/business driven development?Are developers the right people to write documentation?  Should there be a job role that sits somewhere between development and business analysts that produced the documentation?There is a principle of "[url=http://martinfowler.com/bliki/FrequencyReducesDifficulty.html]if it hurts, do it more often[/url]".  You'd think that the development community would have applied their brains to this.I think the problem lies in that business users actually use the end product of software and the idea that continuous integration increases quality and (possibly) speed of delivery is something they can buy into.Technical documentation is something they will never read or see so if the development community whinge about doing it the business is not going to crack the whip to get it done.There is nothing like a healthy dose of outsourcing to shine a glaring light on the inability to write decent requirements.  Every change costs money, the costs can't be lost in internal bureaucracy.</description><pubDate>Mon, 10 Sep 2012 02:08:34 GMT</pubDate><dc:creator>David.Poole</dc:creator></item><item><title>RE: Document First, Code Later</title><link>http://www.sqlservercentral.com/Forums/Topic1356343-263-1.aspx</link><description>[quote][b]pdanes (9/9/2012)[/b][hr][quote][b]gwardell (9/9/2012)[/b][hr]I worked once on a government contract where the entire application was fleshed out in a design tool.  That "application" wound up being the deliverable and the application never made it into a real language.[/quote]Potemkin village, eh? Didn't anyone notice or care that the application didn't do anything?But if the 'users' were satisfied, what the heck. Might even be a way to save on development costs, and the maintenance would certainly be simple.[/quote]It did stuff, it actually updated the database, it was just horribly slow.I guess it was one of the first 4GL RAD systems.</description><pubDate>Sun, 09 Sep 2012 14:49:50 GMT</pubDate><dc:creator>gwardell</dc:creator></item><item><title>RE: Document First, Code Later</title><link>http://www.sqlservercentral.com/Forums/Topic1356343-263-1.aspx</link><description>[quote][b]gwardell (9/9/2012)[/b][hr]I worked once on a government contract where the entire application was fleshed out in a design tool.  That "application" wound up being the deliverable and the application never made it into a real language.[/quote]Potemkin village, eh? Didn't anyone notice or care that the application didn't do anything?But if the 'users' were satisfied, what the heck. Might even be a way to save on development costs, and the maintenance would certainly be simple.</description><pubDate>Sun, 09 Sep 2012 13:30:53 GMT</pubDate><dc:creator>pdanes</dc:creator></item><item><title>RE: Document First, Code Later</title><link>http://www.sqlservercentral.com/Forums/Topic1356343-263-1.aspx</link><description>I worked once on a government contract where the entire application was fleshed out in a design tool.  That "application" wound up being the deliverable and the application never made it into a real language.</description><pubDate>Sun, 09 Sep 2012 07:09:44 GMT</pubDate><dc:creator>gwardell</dc:creator></item><item><title>RE: Document First, Code Later</title><link>http://www.sqlservercentral.com/Forums/Topic1356343-263-1.aspx</link><description>Producing and refining a mock UI up front is invaluable, but be careful to manage user expectations. For many users the UI [b]is[/b] the application and they may not understand that there is still work to be done.</description><pubDate>Sun, 09 Sep 2012 04:36:03 GMT</pubDate><dc:creator>mosaic-287947</dc:creator></item><item><title>RE: Document First, Code Later</title><link>http://www.sqlservercentral.com/Forums/Topic1356343-263-1.aspx</link><description>[quote][b]gwardell (9/8/2012)[/b][hr]I was on a project once where I told NOT to document something because he/they would never read it.Later I was criticized because nobody understood my code.Duh?[/quote]The two are not necessarily inconsistent. Documentation and quality of written code are completely separate issues.</description><pubDate>Sun, 09 Sep 2012 03:36:38 GMT</pubDate><dc:creator>pdanes</dc:creator></item><item><title>RE: Document First, Code Later</title><link>http://www.sqlservercentral.com/Forums/Topic1356343-263-1.aspx</link><description>I was on a project once where I told NOT to document something because he/they would never read it.Later I was criticized because nobody understood my code.Duh?</description><pubDate>Sat, 08 Sep 2012 20:49:38 GMT</pubDate><dc:creator>gwardell</dc:creator></item><item><title>RE: Document First, Code Later</title><link>http://www.sqlservercentral.com/Forums/Topic1356343-263-1.aspx</link><description>[quote][b]call.copse (9/8/2012)[/b][hr]I think I have followed a similar trajectory to Phil. I have spent (literally) years writing specifications in the olden days. We spent approximately 40% on the project time on such. Of course by the time things were actually done they diverged wildly from the original - it is certainly true that on any sizable project you will find any number of previously forgotten issues.[/quote]We used the document then code method with:The documentation was reviewed by the user(s), and the last page held a sign off block which simply stated, "I (we) have reviewed this specification on (fill in date and time) and find it to be an accurate statement of the work required and the required results of said work"[quote] on any sizable project you will find any number of previously forgotten issues[/quote] in which case as the items were found the document was updated with the solution of forgotten issues and again an additional sign off block which simply stated, "I (we) have reviewed this specification on (fill in date and time)  and find it to be an accurate statement of the work required and the required results of said work"I find that today's business culture does not properly measure the cost of doing things over and over ... the old idea of measure twice cut once seems to have disappeared.And miracle of miracles the $$$ required are always found to do it over and over and over and over.</description><pubDate>Sat, 08 Sep 2012 16:54:19 GMT</pubDate><dc:creator>bitbucket-25253</dc:creator></item><item><title>RE: Document First, Code Later</title><link>http://www.sqlservercentral.com/Forums/Topic1356343-263-1.aspx</link><description>I think I have followed a similar trajectory to Phil. I have spent (literally) years writing specifications in the olden days. We spent approximately 40% on the project time on such. Of course by the time things were actually done they diverged wildly from the original - it is certainly true that on any sizable project you will find any number of previously forgotten issues.It appears that there is no longer an ability to justify the upfront expense of such a document and we tend to use wireframing to outline, and daub in the required functionality through the simplest possible text. This seems similar to me to what Phil described. Of course at times we do more or less of this kind of specification depending on the circumstance - the one thing you will never see though, as I acknowledge above is a starting document that actually matches the end point. This does not negate the remarkable value I find achieved by at least getting some facts of the design and how it works pinned down in a document of some kind.</description><pubDate>Sat, 08 Sep 2012 13:20:39 GMT</pubDate><dc:creator>call.copse</dc:creator></item><item><title>RE: Document First, Code Later</title><link>http://www.sqlservercentral.com/Forums/Topic1356343-263-1.aspx</link><description>Happens to me all the time at work but we're trying to utilize the project management group as part of our regular process.  The business knows they must supply requirements to the project manager.  If they fail to do so, we weed out the people that really don't want work.  It's not perfect but it works and if they comply, we get the requirements we need.Mark</description><pubDate>Sat, 08 Sep 2012 12:50:27 GMT</pubDate><dc:creator>Mark Eckeard</dc:creator></item><item><title>RE: Document First, Code Later</title><link>http://www.sqlservercentral.com/Forums/Topic1356343-263-1.aspx</link><description>Sounds nicely politically correct, however, what do you do when the users themselves don't know quite what they want? I run into this a lot - they have a vague idea of what they'd like to achieve, but very little in the way of concrete plans. At some point, pre-production meetings with the users start becoming a rehash of previously stated positions, and no further progress is made in understanding anything. I then create my best guess of what they hope for, and let them start using it. No matter how carefully I follow any plans, there's always loads of things that nobody realized up front, or weren't able to articulate in any comprehensible fashion. If I were to try this method, I would wind up doing much more pointless work, because my documentation of the (yet) unseen interface wouldn't fit the end product anyway.Creating the app first at least lets me write the documentation only once, and often not at all, because in the process of tuning it, I can build in enough pop-up hints, help screens, tooltips and descriptive captions, based on the users' reactions, that I often don't have to write anything - the end-result app is clear and intuitive enough that new users can start to be effective in it with only a minimum of instruction from a colleague.Doing it the way recommended in this post would lead to a lot of wasted time and effort, creating documentation that would not only never get read, but of something that never even existed, and never will. I can think of much better uses for my time.</description><pubDate>Sat, 08 Sep 2012 11:47:19 GMT</pubDate><dc:creator>pdanes</dc:creator></item><item><title>RE: Document First, Code Later</title><link>http://www.sqlservercentral.com/Forums/Topic1356343-263-1.aspx</link><description>This is one of those "in a perfect world "scenarios, in my case.I can see that for large projects, but what about smaller projects or enhancements? There was a recent article about how most of a developers coding time is used for maintenance and enhancements, and not new coding/projects?As a developer, too many times to count I've received vague "one line wonder biz descriptions" from the business analysts describing the desired functionality, and it's up to the developer to flesh out the actual requirements, ramifications, the interfaces, the presentation GUIs, and finally document what it was we created.The #1 problem with that of course, is feature creep: after it gets created from vague biz descriptions,  when it finally gets reviews for QA, they jump in and say that's not what they wanted/imagined, and require additional changes...sigh. You can say that's not right, and say "make them fix it", but in the real world, you can only push so hard.I'd love to get a solid business requirements and documentation like you describe up front for smaller enhancements the same way I would get for large projects.</description><pubDate>Sat, 08 Sep 2012 05:14:19 GMT</pubDate><dc:creator>Lowell</dc:creator></item><item><title>Document First, Code Later</title><link>http://www.sqlservercentral.com/Forums/Topic1356343-263-1.aspx</link><description>Comments posted to this topic are about the item [B]&lt;A HREF="/articles/Editorial/93338/"&gt;Document First, Code Later&lt;/A&gt;[/B]</description><pubDate>Sat, 08 Sep 2012 00:45:22 GMT</pubDate><dc:creator>Phil Factor</dc:creator></item></channel></rss>