Click here to Skip to main content
15,894,997 members
Please Sign up or sign in to vote.
3.00/5 (2 votes)
Hey Guys,

i'am trying to update my database 'AKARAT_ERP'

and set the collation to 'ARABIC_CI_AS'

and i am getting this ERROR

The database could not be exclusively locked to perform the operation.

Any Ideas?
Posted

use following commands

SQL
ALTER DATABASE AKARAT_ERP SET SINGLE_USER WITH ROLLBACK IMMEDIATE
ALTER DATABASE AKARAT_ERP COLLATE ARABIC_CI_AS
ALTER DATABASE AKARAT_ERP SET MULTI_USER
 
Share this answer
 
v2
This error normally occurs when the Database is in use somewhere. Set the database to Single User Mode, do the changes & set the mode to its original
 
Share this answer
 
Comments
_ProgProg_ 25-Sep-13 7:51am    
how could i set the database to single user mode?
SQL
USE master;
GO
ALTER DATABASE AdventureWorks2012
SET SINGLE_USER
WITH ROLLBACK IMMEDIATE;
GO
ALTER DATABASE AdventureWorks2012
SET MULTI_USER;
GO
 
Share this answer
 
v2

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS


CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900