Page 1 of 1
Permission denied on "server_principals" when connecting to MSSQL
Posted: Fri 17 Mar 2017 18:20
by donavan
I have a paid mssql server 2012 in my web host provider. I can configure the connection in dbForge and it's ok. But when I try to open a new query window I get this error:
The SELECT permission was denied on the object 'server_principals', database 'mssqlsystemresource', schema 'sys'
Is there an option to disable or something else to work around this error?
My dbForge version is 5.4.257
Thanks.
Re: Permission denied on "server_principals" when connecting to MSSQL
Posted: Tue 21 Mar 2017 15:57
by alexa
We recommend you to refer to your database administrator on this or dedicated SQL Server forums in the Internet, since we provide technical support only on our products.
Re: Permission denied on "server_principals" when connecting to MSSQL
Posted: Tue 21 Mar 2017 16:59
by donavan
I'm able to access my database using management studio, so it's working.
But when using dbForge, If I open a new query window dbForge tries to use this "server_principals" (it's a system view and I don't have permission to it).
I would like to know if there is a way to dbForge not use this view when opening a new query window.
Thanks.
Re: Permission denied on "server_principals" when connecting to MSSQL
Posted: Wed 22 Mar 2017 09:50
by alexa
Could you please provide us the query you are executing and perform the following:
1. Select 'Tools -> Options...' from the main menu. The 'Options' window opens.
2. Navigate to the 'Environment -> Output' branch.
3. Select the 'Write queries sent by the program to the SQL Log' and 'Log application errors' options.
4. Unselect the 'Delete application log after closing' option. Click 'OK'.
5. Reproduce the issue and send us the error report along with a *.log file with the latest date from the directory:
Code: Select all
%SystemDrive%\Users\%UserName%\AppData\Roaming\Devart\dbForge Studio for SQL Server\
You can send a reply straight to our support system at supportATdevartDOTcom and alexaATdevartDOTcom .
Re: Permission denied on "server_principals" when connecting to MSSQL
Posted: Wed 22 Mar 2017 13:11
by donavan
I've sent the attachments by email.
Thanks.
Re: Permission denied on "server_principals" when connecting to MSSQL
Posted: Fri 24 Mar 2017 14:05
by alexa
Could you please try executing the following query in SSMS:
Code: Select all
USE AdventureWorks2014;
SELECT
sp.principal_id,
sp.name,
sp.sid
FROM sys.server_principals sp;
dbForge requires the metadata returned by this query. If the query also requires some permissions in SSMS, you need to refer to your database administrators.
Re: Permission denied on "server_principals" when connecting to MSSQL
Posted: Mon 27 Mar 2017 13:24
by donavan
I get the same error message when running this query.
But with the SSMS I can access my database e run any query on my tables, I only get this error in SSMS if I try to access Server > Security > Logins, while in dbForge I can't run any query.
I'm contacting my database administrator to see if they can give the permission needed to get this metadata.
But maybe you could consider a new option in configuration so we could choose not get this metadata if we are not going to use it.
Thanks.
Re: Permission denied on "server_principals" when connecting to MSSQL
Posted: Mon 27 Mar 2017 16:44
by alexa
Thank you for the reply.
Could you please clarify on whether there is no access to the sys.server_principals view which means that the SELECT query we provided previously is not executed in SSMS as well as in dbForge?