Take the 2-minute tour ×
Database Administrators Stack Exchange is a question and answer site for database professionals who wish to improve their database skills and learn from others in the community. It's 100% free, no registration required.

I'm using SSMS 2012 to talk to the SQL server 2012 and Azure SQL servers we use. I admit I'm not a SQL expert so I've been saving most of my SQL scripts for future reference. I've quickly run into 20 or so .SQL scripts in the SSMS project and they are all living under the same 'Queries' folder.

Is there a way I can create "sub-folders" in the project so I can organize my scripts properly? How do most other folks keep their scripts organized? I'm pretty sure if this bugs a novice like me, it must be a real issue for real admin (with potentially hundreds of scripts?)

share|improve this question
I have a friend who keeps all his scripts in one giant .sql file. That way you only ever have to keep track of the one file. –  Max Vernon Nov 22 '12 at 20:57
I know of folks that just keep them in a folder that is sync'd to their DropBox account. Then ones that save it on their SkyDrive as well. I am not really one to use the projects in SSMS. –  Shawn Melton Nov 22 '12 at 21:32
This is where Script Manager could come handy, if you get used to it. Though I liked it, for me it kinda didn't click. I just prefer to save my scripts locally, in some folders that I back up on DropBox. Never liked SSMS projects, too. –  Marian Nov 22 '12 at 22:59
you can use SQLTreeo, here' s the tool: sqltreeo.com –  kendra Nov 28 '13 at 15:39
add comment

2 Answers

In SSMS, if you are not already displaying the Template Browser snap-in, go to Menu, View, Template Explorer (hot key Ctrl-Alt-T).

The templates are loaded from your local machine, from this folder

C:\Program Files (x86)\Microsoft SQL Server\110\Tools\Binn\ManagementStudio\SqlWorkbenchProjectItems\Sql

You can add subfolders as you like and even nest them (via Windows Explorer or SSMS). If I am not mistaken the folders are loaded only once per SSMS startup, so you may have to restart SSMS to pick up folder changes from the filesystem.

p/s - This method re-purposes the template browser for the purpose of organising project scripts!

share|improve this answer
Far from an answer but this is the least kludgy hack suggested so far! Thanks for sharing, I'll keep this open for a few more days ... –  DeepSpace101 Nov 23 '12 at 7:15
add comment

Sadly SSMS projects don't support subfolders. If you are talking about the default folder that SQL saves stuff into, yes you can create subfolders in there. That is just a folder on your hard drive. That folder is located in "C:\Users{username}\Documents\SQL Server Management Studio\Projects" by default.

share|improve this answer
add comment

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.