Shortcut: Filters in Object Explorer within SQL Server Management Studio

If you are working with databases with large numbers of objects, the contents of Object Explorer in SQL Server Management Studio can start to become a bit overwhelming. I have to admit that I don’t understand why it doesn’t offer an option to group by schema. That would be helpful.

But you can at least filter by things like schema, when you need to work with a specific set of objects. You’ll notice that if you click on the database name, that the filter in the toolbar is grayed out, but if you click on a node below that like Tables, you can click on the toolbar filter icon. You can also right-click the node and choose to filter:

You then are presented with these options:

That will work to give me just the tables in the Warehouse schema but notice that the operator is Contains. There are other options:

So I could see all the tables except those that are in this schema. Note that Creation Date has even more options:

I can then also use this for other interesting queries such as “Just show me tables that have been created since 1st March:

 

2 thoughts on “Shortcut: Filters in Object Explorer within SQL Server Management Studio”

    1. Hi Linda, the most likely reason for this is that you’ve selected an item that can’t have the filter applied directly. For example, if you select a database, it’s grayed out. If you select “Tables” within a database, it becomes enabled.

Leave a Reply

Your email address will not be published. Required fields are marked *