6

I have created a second database on my existing Azure SQL server. The first database works fine and I can see it using SSMS.

I cannot see the second database in the object explorer. Autocomplete detects that it exists however.

Any suggestions?

  • What version of SSMS are you using? – Sam Cogan Sep 16 '16 at 8:51
  • @Sam 2014 - 12.0.4459.0 – Sam Sep 18 '16 at 22:18
  • Have you resolved your issue yet? – Larry Silverman Sep 28 '16 at 14:48
10

So for me, it turned out that when I was connecting using SSMS, I had set the database to connect to as my first database by accident - meaning that was all I could see.

On connect, go to Options, then check the database you're connecting to. If you're using multiple users to connect to that server like I was, my admin user ended up also being forced to connect to a single database instead of < default >.

  • Ah, that makes sense. I have a few databases I like to be able to connect to quickly. I use the Registered Servers view window and add a New Server Registration for each specific database I need quick access to, specifying the database explicitly in the connection options. – Larry Silverman Apr 3 '17 at 15:18
  • Ding ding ding!!! That was it - been bothering me this whole time :) – Sam Apr 4 '17 at 5:06
  • 1
    Ha thanks, your question turned up when I was having the same problem! Glad I could help :) – Ilessa Apr 4 '17 at 9:06
  • Thanks for your answer, that somehow solved the urgent issue I had too. But I recall you could see more than one DB, if your user had the right privileges, within the same connection. Now it seems I'm stuck with the one DB I select in Options tab. Has something changed? – superjos Apr 17 '18 at 9:10
  • If you leave the DB in the options tab to <default> you can see all the databases that user has permission to see. In my case, I had a user who could only see one DB and (as this user came up first in the list) when I changed user to the one with multiple connections, it didn't change the DB in the Options pane. – Ilessa Apr 23 '18 at 10:21
1

SSMS does not automatically update the database list when new databases are added. You need to refresh the view manually.

In Object Explorer, highlight the Databases node. Hit F5 to refresh. The list of databases should refresh and your new database should appear.

Another method would be to disconnect SSMS from the server and reconnect.

  • Interesting, I have a similar problem (using SSMS 13.0.16106.4) and I've tried both these methods and still can't see the other two databases - I can see them on the portal though – Ilessa Apr 3 '17 at 11:01
  • that didn't work for me. I had to create a new connection despite refreshing about 5 times. I have the same version as @llessa. interestingly I now have TWO instances of the server in object explorer and the original only has one database and the one I just added has the newly added missing database – Simon Apr 15 '17 at 11:02
  • There's an aspect of SSMS 2016 behavior that I've found odd when connecting to Azure SQL Database. Assuming you have admin-level privileges, if you connect and open a query to the Azure SQL server without specifying a default database, you end up in the master database. You can use the database switcher dropdown once, and only once. After that, the switcher cannot be used. It's as though you were not limited to a single database, but after you make a choice, it limits you. I wonder if what you're experiencing is another side-effect of this. – Larry Silverman Apr 17 '17 at 17:28

Your Answer

By clicking "Post Your Answer", you agree to our terms of service, privacy policy and cookie policy

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