• Andy Jones, DBA - Friday, November 17, 2017 3:52 PM

    Jeff Moden - Friday, November 17, 2017 8:18 AM

    The code for the auto-generation of extended properties in this article seems to be just a regurgitation of properties that should be listed elsewhere.  It doesn't explain the purpose of the column at all and that's more of what's almost always missing and more of what is truly needed for a data dictionary.

    Hi Jeff,

    Many thanks for your comment. No, the code to generate the extended property create statements does not explain the purpose of each object or column. We explicitly want to avoid this, as mentioned in the article “It is possible to automate a description such as “this is column A on table dbo.B†but you will end up with some meaningless documentation that tells the reader very little. I wouldn’t recommend doing this.â€

    To create documentation that adds any value, we must manually describe the purpose of each object or column based on our business knowledge.
    The purpose of the generation script is threefold:

    1)      It only generates the sp_addextendedproperty statements for those objects or columns that do not already have an extended property.
    2)      Each extended property create statement includes the user and date. This adds value and creates extended properties with a consistent format.
    3)      It mass produces all the required extended property create statements and avoids having to write each individually or click around the GUI. Once we have the create statement, we must edit the description to clearly describe the purpose of the object and hit F5.

    Thanks again, Andy.

    Exactly.  It's going to take a human to document the columns of the table. 

    BTW... I only pointed out the part I disagreed with.  Thank you very much for stepping up and writing an article!

    --Jeff Moden


    RBAR is pronounced "ree-bar" and is a "Modenism" for Row-By-Agonizing-Row.
    First step towards the paradigm shift of writing Set Based code:
    ________Stop thinking about what you want to do to a ROW... think, instead, of what you want to do to a COLUMN.

    Change is inevitable... Change for the better is not.


    Helpful Links:
    How to post code problems
    How to Post Performance Problems
    Create a Tally Function (fnTally)