0

I've done the following on my SQL Azure instance:

1) Add a new login 2) Create a new user on my database from that login 3) Granted db_datareader to that user on that database

I can use that user to connect through SQL Server Management Studio, and I can expand the "Databases" node in the Object Explorer, but once I try to right-click the database to select "New query", the whole UI freezes for about 30 seconds.

I can connect and do the same thing with the db_owner, and it works without a problem.

Is there some other role/right I have to give to the user?

  • What about through the Azure portal? – Jacob H Jun 26 '17 at 14:56
  • 1
    And what about right click on the server, and choose new query. It's the same? Can you try through sqlcmd? – Renato Afonso Jun 26 '17 at 16:53
  • Right click on the server -> "New query" works, and it opens the correct database. – Petter Brodin Jun 27 '17 at 6:37
1

Please run the following statement on the Master database and that should do the trick

CREATE USER LoginName FROM LOGIN LoginName

Hope this helps.

Regards,

Alberto Morillo

0

Please provide the following permissions to that new login :

GRANT CONNECT TO YourNewLogin;

GRANT SELECT TO YourNewLogin;

Hope this helps.

  • Alberto, try to avoid self-promotion in your posts as per the guidelines. You should add your website to your profile, which is available through every post you make, if you'd like to show your affiliation. – LowlyDBA Jun 26 '17 at 15:26
  • That didn't work. Like I describe above, the user can already connect, but once connected he can't right-click the database he has the DB_READER role on. – Petter Brodin Jun 27 '17 at 6:40

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.