Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 General SQL Server Forums
 New to SQL Server Programming
 Attempting to create first database - error

Author  Topic 

scottish racer
Starting Member

1 Post

Posted - 2007-02-17 : 19:20:34
I've just installed SQL Server Express and attempted to create my first database and received this error message :-(

Maybe this is a long shot, but can someone tell me what I've done wrong? Do I have a bad install or what?

Essentially I followed the steps below to create the database:

1. Started MS SQL Server Management studio Express
2. Right clicked on the Database folder
3. Selected "New Database..."
4. New Database panel displayed
5. Entered name of database - pip
6. Clicked "OK"
7. Receieved error dialog with followig message:

TITLE: Microsoft SQL Server Management Studio Express
------------------------------

Create failed for Database 'pip'. (Microsoft.SqlServer.Express.Smo)

For help, click: http://go.microsoft.com/fwlink?ProdName=Microsoft+SQL+Server&ProdVer=9.00.2047.00&EvtSrc=Microsoft.SqlServer.Management.Smo.ExceptionTemplates.FailedOperationExceptionText&EvtID=Create+Database&LinkId=20476

------------------------------
ADDITIONAL INFORMATION:

An exception occurred while executing a Transact-SQL statement or batch. (Microsoft.SqlServer.Express.ConnectionInfo)

------------------------------

Could not obtain exclusive lock on database 'model'. Retry the operation later.
CREATE DATABASE failed. Some file names listed could not be created. Check related errors. (Microsoft SQL Server, Error: 1807)

For help, click: http://go.microsoft.com/fwlink?ProdName=Microsoft+SQL+Server&ProdVer=09.00.2047&EvtSrc=MSSQLServer&EvtID=1807&LinkId=20476

------------------------------
BUTTONS:

OK
------------------------------


madhuotp
Yak Posting Veteran

78 Posts

Posted - 2007-02-18 : 05:41:57
check whether the Model Database is AutoColse enabled...
select DATABASEPROPERTY ('model' , 'IsAutoClose') -- if this statement return 1 means Autoclose ON
set this property false and try

if this is not the case check this link http://msdn2.microsoft.com/en-us/library/aa337268.aspx
as said, disconnect all the connection to the MOdel database and try

Madhu






Madhu
Go to Top of Page
   

- Advertisement -