Raven Dreamer
Raven Dreamer

Reputation: 7140

Permissions Problems Prevent Database Access

Recently I inherited a database from another programmer (created / stored with SQL Management Studio 2008), and I am having massive difficulties accessing, modifying, or even viewing the previously created databases.

Specifically, when I try to load one of the databases in SQL Management Studio I get the following error message:

"The database [database name] is not accessible. (Object Explorer)"

I am connecting to the SQL server with windows authentication.

Anyway, is this a permissions issue left over from the last dev? (he's unavailable, unfortunately) And is there an easy work-around short of completely reinstalling SQL Management Studio?

Edit: Update:

Upon trying to access User Mapping, as suggested below, I got the following error message:

"One or more databases are inaccessible and will not be displayed in list."

Unfortunately, none of the databases I am trying to access appeared in the list, so I assume they are still inaccessible.

Upvotes: 3

Views: 29886

Answers (4)

John Waclawski
John Waclawski

Reputation: 996

In our case we found out that our Always On (AO) cluster was messed up. Rebooted the cluster, everything came back up & we were no longer getting that error.

Upvotes: 0

Diana Vallverdu
Diana Vallverdu

Reputation: 381

This message:

"One or more databases are inaccessible and will not be displayed in list."

Means that the user you are using right now cannot access to that db. If you can enter with a user that does have access and from that user change your actual user's rights through User Mapping, then you will see it.

Upvotes: 1

HLGEM
HLGEM

Reputation: 96542

You need a dba (or someone with dba equivalent access) to give you rights to the database.

Upvotes: -2

TLiebe
TLiebe

Reputation: 7966

It could very well be a permissions problem. If you open Object Explorer in SQL Server Management Studio and expand the Security node (the one under the server instance, not the Security tab under the individual databases) and then expand the Logins node you'll see the list of logins that have been created on the server. Have a look at the properties of each of those and check out the User Mapping information. You'll be able to see which logins are mapped to which databases. It's possible the previous programmer only granted access to the database to certain logins. If you find a login that's mapped to the database you want, try changing the password of the login and then connecting to the database with that login and password. NOTE: be careful when changing the password as it may affect production applications that are using that login and password!

Upvotes: 3

Related Questions