SQl Server Management Studio - Tabs & Indenting option - Convert

  • Evening,

    Our team all had SQL Server management Studio installed for us but I have recently discovered that my stored procedures display differntly due to tab settings which had been set differently as a default upon install.

    Tools> Options> Text Editor > Transact-SQL> Tabs.

    My setting for the above on Tab Size and Indent size is 4 whereas the rest of the team had it set as 8. This means that none of my stored procedures are displayed correctly on their machines.

    Due to the way we indent our code for easy reading mine is widly messy when displayed on colleagues machines but neat on my own. I need to convert my files to the same settings.

    I have written at least 1000 stored procedures which I can't convert one by one so does anyone know a way i can bulk convert all my files to have the same tab settings?

    I surely can't be the only one that has had this issue.

    Can anyone help me with a method of resolving this please?

  • Something like SQL Pretty Printer may be of help.

    There is a desktop version which can convert all files within a folder. A demo is available at http://www.dpriver.com/index.php.

  • I will check this out and see if it can resolve the problem and let you know. Thank you.

  • Another option is poorsql.com Just have them copy and paste the proc, then get the formatted version and copy and paste it back into the editor. I only use this when I encounter problematic looking SQL; no reason to change it if I am not looking at it.

    Jared
    CE - Microsoft

  • +1 [SQL Pretty printer]

    I am also using this tool. Once installed it adds into ur menu tab as SQL Beautifer. Check it out..its a cool tool 🙂

    ~ Lokesh Vij


    Guidelines for quicker answers on T-SQL question[/url]
    Guidelines for answers on Performance questions

    Link to my Blog Post --> www.SQLPathy.com[/url]

    Follow me @Twitter

  • BrainDonor (7/25/2012)


    Something like SQL Pretty Printer may be of help.

    There is a desktop version which can convert all files within a folder. A demo is available at http://www.dpriver.com/index.php.

    Also, have to had them change their settings back to 4? That's the "norm."

    Jared
    CE - Microsoft

  • My tabs are set to 4 as well, but I also have SSMS replace tabs with spaces.

Viewing 7 posts - 1 through 7 (of 7 total)

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