Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
CODE PROJECT For Those Who Code
  • Home
  • Articles
  • FAQ
Community
  1. Home
  2. Database & SysAdmin
  3. Database
  4. Problems with CREATE DATABASE

Problems with CREATE DATABASE

Scheduled Pinned Locked Moved Database
csharpdatabasevisual-studiosysadminhelp
3 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • F Offline
    F Offline
    Frederick S Jones
    wrote on last edited by
    #1

    When I try to create a database in VS.NET thru the Server Explorer window I get this error: ADO Error: 'Could not obtain exclusive lock on database 'MODEL'. Retry the operation later. CREATE DATABASE failed. Some file names listed could not be created. Check previous errors.' I'm running VS.NET Professional with MSDE 2000, so this should work, I think. Anybody else here seen this error? Is there anything I can do about it? I'm not seeing anything in the log files concering what's causing this... Get that finger out of your ear! You don't know where that finger's been!

    C 1 Reply Last reply
    0
    • F Frederick S Jones

      When I try to create a database in VS.NET thru the Server Explorer window I get this error: ADO Error: 'Could not obtain exclusive lock on database 'MODEL'. Retry the operation later. CREATE DATABASE failed. Some file names listed could not be created. Check previous errors.' I'm running VS.NET Professional with MSDE 2000, so this should work, I think. Anybody else here seen this error? Is there anything I can do about it? I'm not seeing anything in the log files concering what's causing this... Get that finger out of your ear! You don't know where that finger's been!

      C Offline
      C Offline
      Colin Angus Mackay
      wrote on last edited by
      #2

      Hmmmm... "MODEL" is the database that is used as a template for all new databases, it shouldn't ordinarily be written to. The exclusive lock is probably requested to prevent others from updating MODEL while a new database is in the process of being created. My suggestion is to check to see if any processes are accessing MODEL and stop them.


      EuroCPian Spring 2004 Get Together[^] "You can have everything in life you want if you will just help enough other people get what they want." --Zig Ziglar

      F 1 Reply Last reply
      0
      • C Colin Angus Mackay

        Hmmmm... "MODEL" is the database that is used as a template for all new databases, it shouldn't ordinarily be written to. The exclusive lock is probably requested to prevent others from updating MODEL while a new database is in the process of being created. My suggestion is to check to see if any processes are accessing MODEL and stop them.


        EuroCPian Spring 2004 Get Together[^] "You can have everything in life you want if you will just help enough other people get what they want." --Zig Ziglar

        F Offline
        F Offline
        Frederick S Jones
        wrote on last edited by
        #3

        Your suggestion worked - for some dumb reason I tried to do this while connected to the databases...all of them. :doh: But when I tried to create the new db while only being connected to the instance, it worked. Yeah, I'm new at this... Thanks for your help :) Frederick S Jones
        "Get that finger out of your ear! You don't know where that finger's been!"

        1 Reply Last reply
        0
        Reply
        • Reply as topic
        Log in to reply
        • Oldest to Newest
        • Newest to Oldest
        • Most Votes


        • Login

        • Don't have an account? Register

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • World
        • Users
        • Groups