December 16, 2015 by Kenneth Fisher
A few weeks ago I was reading a blog post by Andrea Allred (b/t) and was just amazed by what I was reading. I’ve never been a big fan of the Object Explorer Details window. It didn’t seem to really add anything. But Andrea pointed out that it will actually let you script (or delete) multiple objects at once.
First a demo then some discussion.
You can open this window by either hitting F7 or by going to the View >> Object Explorer Details.
Then you can navigate to the objects you are interested in (tables, views, stored procedures etc). Note: As the name implies the Object Explorer Details window is linked to what you have selected in the Object Explorer.
Now select one or more objects. You can select multiple objects by using the shift or control key just like in Windows File Explorer. From there you right click on one of the selected objects and select either delete or script.
There are other methods of doing this of course, which I plan on going into in another post, but for now this has some great benefits. First of all you can filter the list just like in object explorer. So if you need to script just a portion of your 1000+ stored procedures you can filter the list first to make it easier to find them. Then let’s say you want to script all (or most) of a type of object, or filtered list of objects. Just hit control-A to select them all, then unselect anything you don’t want to script by using the control key and the mouse.
Nice little productivity tip hu? Thanks Andrea!