(Microsoft SQL Server, error: 916). Same behavior running SQL Server Management Studio as administrator or not in PC1. I do not have any idea to solve this problem. You receive SQL Server error 916 when you try to delete a document in Edit/Select Documents for Payment Content provided by Microsoft Applies to: Microsoft Dynamics SL 2011 Service Pack 3 Accounts Payable. (Microsoft SQL Server, Error: 916) I know, this is a very rare thing, and if you change something and then things quit working, you’ll probably put 2 + 2 together to know what happened. But just in case an admin removes it and you can’t access your databases through SSMS any more, well, there you go.
Active2 years, 8 months ago
I'm using Microsoft SQL Server 2012 Management Studio Express. I have detached one of my databases (it was in my office server) and
.mdf
and .ldf
files are saved to MSSQL
folder (on my local server). While I was detaching the database it was saying that with my connections (hopefully the server) cannot detach the database. Then I selected the drop connections option in the detach mode. Now when I try to attach the database it doesn't allow me to attach. When I click the add button doesn't give me the option to browse my folder. Below error message is showing.
Failed to retrieve data for this request.(Microsoft.SqlServer.Management.Sdk.Sfc)
Additional information:
An exception occurred while executing a Transact-SQL statement or batch.(Microsoft SQL server. connectionInfo).
The server principal 'my username' is not able to access the database 'model' under the current security context.(Microsoft SQL server, Error:916).
What should I do? Please help me.
marc_s606k137137 gold badges11601160 silver badges12921292 bronze badges
UdithUdith
2 Answers
To resolve the issue... follow the given steps.(1) Start sqlserver and login(2) Press 'F7' or click on 'View->Object Explorer Details' to open Object Explorer Details window.(3) You will see there column header.. like 'Name', 'Policy Health State', 'Recovery Model', 'Collation' etc.(4) Right click on the header and unselect the 'Collation'.(5) Now refresh the database folder. You will get all database list.
Login Failed For User Microsoft Sql Server Error 916
MohammedAshrafaliMohammedAshrafali14111 gold badge33 silver badges1717 bronze badges
It's not a problem with the actual attach statement, but rather with setting up the wizard UI (which is a shame IMO). Use T-SQL to attach the database instead:
You'd be better off to use T-SQL all the time instead of SSMS wizards. Or use wizard to script out the action and execute in a query window.
Also, check what's the problem with the permissions on model. Use this query to see if there's any
deandeanDENY
:8,68922 gold badges1616 silver badges2121 bronze badges
Not the answer you're looking for? Browse other questions tagged sqlsql-serversql-server-2008 or ask your own question.
-->This article lists common troubleshooting question.
Connecting
Issue | Resolution |
---|---|
Login failed for user 'NT AUTHORITYANONYMOUS LOGON'. (Microsoft SQL Server, Error: 18456) | This error occurs when an AAD user tries to connect to the master database, but does not have a user in master. To correct this issue, either specify the SQL Data Warehouse you wish to connect to at connection time or add the user to the master database. See Security overview article for more details. |
The server principal 'MyUserName' is not able to access the database 'master' under the current security context. Cannot open user default database. Login failed. Login failed for user 'MyUserName'. (Microsoft SQL Server, Error: 916) | This error occurs when an AAD user tries to connect to the master database, but does not have a user in master. To correct this issue, either specify the SQL Data Warehouse you wish to connect to at connection time or add the user to the master database. See Security overview article for more details. |
CTAIP error | This error can occur when a login has been created on the SQL server master database, but not in the SQL Data Warehouse database. If you encounter this error, take a look at the Security overview article. This article explains how to create a login and user on master, and then how to create a user in the SQL Data Warehouse database. |
Blocked by Firewall | Azure SQL databases are protected by server and database level firewalls to ensure only known IP addresses have access to a database. The firewalls are secure by default, which means that you must explicitly enable and IP address or range of addresses before you can connect. To configure your firewall for access, follow the steps in Configure server firewall access for your client IP in the Provisioning instructions. |
Cannot connect with tool or driver | SQL Data Warehouse recommends using SSMS, SSDT for Visual Studio, or sqlcmd to query your data. For more information on drivers and connecting to SQL Data Warehouse, see Drivers for Azure SQL Data Warehouse and Connect to Azure SQL Data Warehouse articles. |
Tools
Issue | Resolution |
---|---|
Visual Studio object explorer is missing AAD users | This is a known issue. As a workaround, view the users in sys.database_principals. See Authentication to Azure SQL Data Warehouse to learn more about using Azure Active Directory with SQL Data Warehouse. |
Manual scripting, using the scripting wizard, or connecting via SSMS is slow, not responding, or producing errors | Ensure that users have been created in the master database. In scripting options, also make sure that the engine edition is set as “Microsoft Azure SQL Data Warehouse Edition” and engine type is “Microsoft Azure SQL Database”. |
Generate scripts fails in SSMS | Generating a script for SQL Data Warehouse fails if the option 'Generate script for dependent objects' option is set to 'True.' As a workaround, users must manually go to Tools -> Options ->SQL Server Object Explorer -> Generate script for dependent options and set to false |
Performance
Issue | Resolution |
---|---|
Query performance troubleshooting | If you are trying to troubleshoot a particular query, start with Learning how to monitor your queries. |
Poor query performance and plans often is a result of missing statistics | The most common cause of poor performance is lack of statistics on your tables. See Maintaining table statistics for details on how to create statistics and why they are critical to your performance. |
Low concurrency / queries queued | Understanding Workload management is important in order to understand how to balance memory allocation with concurrency. |
How to implement best practices | The best place to start to learn ways to improve query performance is SQL Data Warehouse best practices article. |
How to improve performance with scaling | Sometimes the solution to improving performance is to simply add more compute power to your queries by Scaling your SQL Data Warehouse. |
Poor query performance as a result of poor index quality | Some times queries can slow down because of Poor columnstore index quality. See this article for more information and how to Rebuild indexes to improve segment quality. |
System management
Issue | Resolution |
---|---|
Msg 40847: Could not perform the operation because server would exceed the allowed Database Transaction Unit quota of 45000. | Either reduce the DWU of the database you are trying to create or request a quota increase. |
Investigating space utilization | See Table sizes to understand the space utilization of your system. |
Help with managing tables | See the Table overview article for help with managing your tables. This article also includes links into more detailed topics like Table data types, Distributing a table, Indexing a table, Partitioning a table, Maintaining table statistics and Temporary tables. |
Transparent data encryption (TDE) progress bar is not updating in the Azure portal | You can view the state of TDE via powershell. |
Differences from SQL Database
Issue | Resolution |
---|---|
Unsupported SQL Database features | See Unsupported table features. |
Unsupported SQL Database data types | See Unsupported data types. |
DELETE and UPDATE limitations | See UPDATE workarounds, DELETE workarounds and Using CTAS to work around unsupported UPDATE and DELETE syntax. |
MERGE statement is not supported | See MERGE workarounds. |
Stored procedure limitations | See Stored procedure limitations to understand some of the limitations of stored procedures. |
UDFs do not support SELECT statements | This is a current limitation of our UDFs. See CREATE FUNCTION for the syntax we support. |
Next steps
For more help in finding solution to your issue, here are some other resources you can try.