• Let me answer the responses to my article so far in this way.  First, this article was not written to discuss this subject in any depth.  It is targeted toward the beginning DBA and SQL Programmer.  I didn't believe it needed to go into great depth since it will be rare that a need to create one comes up. 

    I found a need a few years ago and so created one.  The only system stored procedure I have ever created and placed in the master database is the one I talked about briefly in the article.  It simply scripts a table with its indexes and default values.  The script can be found in SQL Server Centrals script library for those interested.

    Next,  I believe it is useful to learn all about SQL Server.  Even things that you would never consider doing in a production environment.  So, if you consider this to be one of those things you will never do, that is fine.  I don't think it will hurt you to know how to create a system stored procedure and be aware of the possible problems associated with doing so.

    I believe there are many schools of thought on how code should be generated.  I learned from my mentor to put SQL in upper case and to put variable names with the first letter of each significant word in upper case and the rest of the characters in lower case. 

    Should you wish to see some different styles go look at the system stored procedures that Microsoft created.  Some examples of the different styles they used are found in sp_configure (almost every character is in lower case), sp_denylogin (some if's are in upper case and some in lower case),  and sp_dropmergearticle (here keywords in the same query are both upper case and lower case).

    Robert W. Marda
    Billing and OSS Specialist - SQL Programmer
    MCL Systems