Solved

SQL Server Management Studio error 916

Posted on 2013-01-21
5
562 Views
Last Modified: 2013-01-29
We are trying to detach a database from an old server so we can run it on a new server.

On the old machine, when I stop the destiny service and then try to detach the database I keep getting an error (error 916) saying that it cannot be performed under the current security context. I am using an administrators account.

I tried the MS fix for error 916.. still doesn’t work.

Any ideas?
0
Comment
Question by:dazzaster
5 Comments
 
LVL 42

Accepted Solution

by:
EugeneZ earned 250 total points
Comment Utility
please verify if you are using sql server Sa role permissions ;
are you local win admin? sql server service is running as win admin too?

Reasons for SQL Server Error 916

<Here are some possible reasons for SQL Server Error 916:
•A login does not have permission to view data of a column selected in the header
•A database is offline and/or its collation is NULL
•Multiple databases with different collations are on the instance and SSMS is unable to retrieve the collation because a database is configured to auto-close>
more
http://www.mssqltips.com/sqlservertip/2761/sql-server-management-studio-error-916/
0
 
LVL 42

Expert Comment

by:EugeneZ
Comment Utility
btw: what sql server edition\version do you use?
what sSMS version was used?


try to use
sp_detach_db
http://msdn.microsoft.com/en-US/library/ms188031(v=SQL.90).aspx


The following example detaches the AdventureWorks database with skipchecks set to true.

EXEC sp_detach_db 'AdventureWorks', 'true';
0
 
LVL 21

Expert Comment

by:mastoo
Comment Utility
You don't want to do a backup of the database, copy the backup file, and use that to restore on the new server?
0
 
LVL 35

Assisted Solution

by:David Todd
David Todd earned 250 total points
Comment Utility
Hi,

A Windows Administrators account is not necessarily a SQL Database Administrators account.

Often in the past they were, but may pay to check you really do have the system admin role on this SQL instance.

Regards
  David

PS And what mastoo said above ... restore of backup better than detaching anything if production
0
 
LVL 1

Author Closing Comment

by:dazzaster
Comment Utility
Wasn't using SA account
0

Featured Post

What Is Threat Intelligence?

Threat intelligence is often discussed, but rarely understood. Starting with a precise definition, along with clear business goals, is essential.

Join & Write a Comment

Use this article to create a batch file to backup a Microsoft SQL Server database to a Windows folder.  The folder can be on the local hard drive or on a network share.  This batch file will query the SQL server to get the current date & time and wi…
In this article we will get to know that how can we recover deleted data if it happens accidently. We really can recover deleted rows if we know the time when data is deleted by using the transaction log.
Via a live example combined with referencing Books Online, show some of the information that can be extracted from the Catalog Views in SQL Server.
Via a live example, show how to setup several different housekeeping processes for a SQL Server.

771 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now