~phinze/mssql---find-table-across-mul..._

moi

Who?

I'm Paul Hinze. I live in Chicago. I'm a developer at Braintree Payment Solutions.

MSSQL - find table across multiple databases

published 12 Nov 2009

We have a server at work with a legacy system that uses a lot of databases. Sometimes I find myself in management studio looking and looking for a table that I just can’t seem to find.

Here’s a little snippet I found when I finally decided to look around for a better solution than lumbering around the database server till I bumped into my table.

When searching for table names starting with ‘FOO’:

The answer comes back as many result sets (one per database) which is a little clunky, but it’s short, and it gets the job done. Plus I get wildcards. Neato.

(via)