SQL Server Documentor

  • Rudy Panigas (9/29/2014)

    SQLQuest29 (1/2/2014)

    Highly suggest to look into : SQL Server & Windows Documentation Using Windows PowerShell[/url] by Kendal Van Dyke

    It collects much more info and is flexible.

    Why would I use PowerShell when the information you need can be collected with T-SQL scripting. Maybe you could create the PowerShell and post the script?

    Personally I'm not into PowerShell, feel like is a programming language for System administrators and Database administrators.

    Because it is easy to automate using PowerShell. Kendal has put in a lot of efforts and the script that he does a lot of better checks than u have. So its better not to reinvent the wheel.

    HTH !
    MCTS : 2005, 2008
    Active SQL Server Community Contributor 🙂

  • [/quote]

    Because it is easy to automate using PowerShell. Kendal has put in a lot of efforts and the script that he does a lot of better checks than u have. So its better not to reinvent the wheel.[/quote]

    Hey, all power to PowerShell developers! If there is a better script then please use it. I and others that have tested and used this script have found it to work very will and fits their needs. I didn't write the script to compete, just to provide a way to get useful information from within SQL Sever itself.

    I personally don't spend time in PowerShell as I would rather spend my time learning more on performance tuning/enhancements, high availability and disaster recovery.

    Thanks for your comments 🙂



  • A couple notes... I'll get notification if you post in the discussion when you update the page... or at least I hope I will....

    Coming up with Powershell wrapper for a t-sql script might be useful for someone interested in powershell. For logistical reasons I really appreciate that the script is in t-sql. A SQL connection to a site is generally easier for me to obtain than GUI session.

  • Nice script, though I see one issue: the SSIS service registry key name MsDtsServer is valid only for SQL2005. It was subsequently renamed MsDtsServer100, MsDtsServer110, and MsDtsServer120 in SQL 2008, 2012, and 2014 respectively. This of course could just be handled with a CASE based on SERVERPROPERTY ('productversion').

    You might also want to gather the accounts under which the services are running, which you'll find in the ObjectName value under the service key, e.g. something like:

    EXEC xp_regread N'HKEY_LOCAL_MACHINE', @REGKEY, N'ObjectName', @MSSQLServiceAccountName OUTPUT, N'no_output'

  • Rudy, hi!

    Regarding this portion of script :


    --> SQL Server Settings <--

    EXEC sp_configure 'show advanced options', 1;











    INTO #SQL_Server_Settings

    FROM master.sys.configurations


    EXEC sp_configure 'show advanced options', 0;





    There's no need to neither switch advanced options ON, nor OFF, because "select * from master.sys.configurations" will return the same amount of information in both cases.

    I mean this option doesn't affect the amount of records returned by select.



  • Nice sql script. It even can pick up those long funny database names of SharePoint.



  • Looks like your script doesn't include MS SQL Resource database.

    32767 data C:\Program Files\Microsoft SQL Server\MSSQL10_50.DEV\MSSQL\Binn\mssqlsystemresource.mdf

    32767 log C:\Program Files\Microsoft SQL Server\MSSQL10_50.DEV\MSSQL\Binn\mssqlsystemresource.ldf

  • Yes you're right. I didn't write the code for that section yet.



  • I am waiting for your new version.

    Thanks again!


  • Thanks for the script Rudy.

Viewing 10 posts - 16 through 24 (of 24 total)

You must be logged in to reply to this topic. Login to reply