title: Limit Database List to Ones With Permission SQL Server
body: <p>By default if you connect to a remote SQL Server via an account that has access to say 1 of the 10 databases.  You will still see in the Object Explorer all other databases, obviously due to permissions you cannot actually query them, but you can see their names.</p>
  
  <p>I have heard that there is a method that disable this behavior, but I've been unable to find the answer, does anyone know how to do this?  To give an example I have a SQL Server called MyDbServer, it has 4 databases, </p>
  
  <ol>
  <li>MyDatabase</li>
  <li>YourDatabse</li>
  <li>PrivateDatabase</li>
  <li>ReallyPrivateDb</li>
  </ol>
  
  <p>If you connect via an account that only has permissions to "YourDatabse" you will still see a listing of all other databases, attempts to query will grant "select" permission denied or a similar error.</p>
  
  <p>For security resons, we DO NOT want users to see any database other than the ones they are mapped to.</p>